[Solar-talk] Sungrazr_Server: Request for comments

Rodrigo Moraes rodrigo.moraes at gmail.com
Sun Mar 9 03:49:00 CDT 2008


On Wed, Dec 19, 2007 at 7:04 AM, Antti Holvikari wrote:
>  Also, why not just prefix methods with something like "api" to inform
>  it's callable instead of @supports? "Coding" with docblocks seems
>  weird to me :-).

Now looking closer at it, the docblocks make sense. @supports, for
example, is used like this:

    @supports post, get, put, delete

...to inform that the requested api accepts all these HTTP methods. If
it didn't used docblocks, this should be defined in config or in a
property.  Using docblocks seems cleaner.

Other use is for @restricted, where the api is only evoqued if the
caller is authenticated, also avoiding extra definitions or checkings
for restricted/non-restricted methods.

-- rodrigo, working on a simple REST adapter :-)


More information about the Solar-talk mailing list