Re: Leaf Resources with child Leaf Resources

Jacek Furmankiewicz <[email protected]>
Newsgroups gmane.comp.python.twisted.web
Message-ID <CAGDztiHQr2ExD5Ev9gA8prkj32swTWJDGmvh8zNx44SjtyW-6Q@mail.gmail.com>
Well, maybe this will explain what I want to achieve, based on latest
(already working) code from trunk:

A sample of a REST app with two REST services exposed

https://github.com/jacek99/corepost/blob/master/corepost/test/rest_resource.py

There is a generic RESTResource (an actual twisted.web Resource) that
register child REST services (just regular classes).
It takes care of routing all the requests to them.

A human readable BDD that shows the unit tests for it:
https://github.com/jacek99/corepost/blob/master/corepost/test/feature/rest_app.feature

I am getting pretty happy with this API. It achieves what I wanted, needs
more thorough testing though before I release
an official version with it.

Cheers
Jacek

On Fri, Mar 2, 2012 at 9:18 AM, <[email protected]> wrote:

> On 1 Mar, 02:59 pm, [email protected] wrote:
> >That is exactly what I wanted to do (i.e. custom dispatching to child
> >classes from a single leaf Resource).
>
> This sounds like the opposite conclusion as Jonathan (and earlier, me)
> was suggesting.  However, you trimmed *all* context from this reply, so
> perhaps I am not correctly interpreting you.
>
> Anyway, good luck.
>
> Jean-Paul
>
> _______________________________________________
> Twisted-web mailing list
> [email protected]
> http://twistedmatrix.com/cgi-bin/mailman/listinfo/twisted-web
>

_______________________________________________
Twisted-web mailing list
[email protected]
http://twistedmatrix.com/cgi-bin/mailman/listinfo/twisted-web
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.