On Fri, 13 Oct 2006 10:25:12 -0500, Manlio Perillo
<[EMAIL PROTECTED]> wrote:
L. Daniel Burr ha scritto:
[SNIP]
No, it is thanks to "tree of resources" design, that guard can do its
job. That is not the same thing as saying that every segment has a
template. Some resources do *not* render anything; instead, via
locateChild, or other mechanisms, they return other resources.
Then I don't understand what do you mean by "template-per-segment"
design...
In the URL http://myhost.com/foo/bar/baz, the resource living at baz
depends upon foo and bar because of the "tree of resurces" design.
Sorry, I realize terminology can be imprecise and confusing in many
cases. "template-per-segment", as I am using it, means this: each
segment in the URL corresponds to an HTML/XML/XHTML/Whatever template.
In nevow, this does not have to be the case. A resource might only
return child resources, and have no template of its own. In fact,
this is one of the really useful things about the tree-of-resource
structure: Some resources have concrete representations, and some
are purely logical.
The point I am trying to make, and have apparently failed to make,
is that URL segment != markup snippet. A "template-per-segment"
design means that every segment must have a corresponding template
that gets rendered as some kind of markup. It also means that each
template depends on markup from the template containing it, which
is what I am objecting to so strenuously.
Also, your statement that "baz" depends upon "foo" and "bar" is not
necessarily true. "baz" is clearly contained within "bar", which is
contained within "foo". Containment != dependency. This does not
preclude enforcing a dependency if you so desire, but I think that
mandating such a dependency is unnecessary and limiting.
Is this explanation any clearer?
Regards Manlio Perillo
L. Daniel Burr
_______________________________________________
Twisted-web mailing list
[email protected]
http://twistedmatrix.com/cgi-bin/mailman/listinfo/twisted-web