Agavi PHP Framework

Agavi PHP Framework

Posts 1-1 of 1
  • David Zülke
    David Zülke    Premium Member   Group moderator
    The company name is only visible to registered members.
    Agavi 1.0.0 beta 9 released!
    Hi everyone,

    Agavi 1.0.0 beta 9 is now available for download at http://www.agavi.org/.

    This release includes a relatively modest number of changes over 1.0.0 beta 8:
    - Testing infrastructure (experimental!) was declared "finished" (it will be changed and improved until at least 1.1)
    - Routing callbacks can now return an AgaviResponse from onMatched() and onNotMatched()
    - Cache group callbacks need to throw an exception of type AgaviUncacheableException now to prevent caching
    - Routing callbacks now have onNotMatched() called by the framework, even if the same callback's onMatched() method returns false
    - Several regressions were fixed in the new Routing.
    As always, the CHANGELOG has a complete list of all changes.

    There is, however, one new feature that I'd like to devote special attention to:

    A new API for accessing information about the result of a validation run is now available through AgaviValidationManager::getReport().
    It is vastly more convenient and capable of the previous APIs which have been deprecated.

    The primary instrument for accessing validation result information are query objects, which you can retrieve using AgaviValidationReport::createQuery().
    They have methods for defining query filter rules (byArgument, byValidator, byMinSeverity, byErrorName), which form a fluent interface.
    Methods like has(), count() or getErrorMessages() are available to retrieve information from the resulting collection.

    This new interface allows you to query *any* kind of result from the validation system in just one (albeit long) line of code, and we're pretty excited about it, because, frankly, the old APIs were a bit of a mess and not very intuitive to use.

    Be sure to check out http://trac.agavi.org/ticket/1022 to see some examples on how to use the new interface.

    We'll release an RC1 very soon now, so stay tuned, friends!

    - David