Hi,

 

  I have a question about where to place my files in Tapestry 4. In Tapestry
3.x I was used to specify my pages and components in my .application file
and place them anywhere I wanted to. I placed the files depending on my
application structure so that they would always be in a nice organized way
and very easy to find. Under my WEB-INF folder I had a "pages" and a
"components" folder and they where further organized from there. In Tapestry
4 I can simply continue to do that and everything will be fine, but I guess
I'll lose the advantage of having simple pages and components without a
specification file.

  I wouldn't mind at all having to specify in the .application file where
each page and component is since I would continue to get exactly the
separation I want between my files, but from what I've learned so far,
Tapestry 4 does not allow you to specify pages and components in the
.application file without an associated specification file. According to the
docs, if I place my html files starting at the context root and specify the
java packages for the page classes I'll be ok and won't need to specify any
pages in the .application file. Sure, I'll have to reference my pages with
their full path in my app (eg. account\LoginPage), but I actually prefer it
that way. I even tried it out. It's great!

  The problem I have is with the components. (I read on the list that there
is a bug that won't allow you to create components without a specification
file, but I don't know exactly what the bug is. For this argument, let's
suppose there is no bug). If a component without a specification file works
the same way as a page, it will search for any .html files in the context
root, just like the pages. This would mean that I would necessarily have to
have the html files for my pages together with my components, which is not
good for keeping things organized. Also, if I can't just do a
"jwcid='@account\LoginComponent" then there is no way I can have components
that are not in the .application file, which means I must have a
specification file for each component.

 

So my question is actually three:

 

Will there be any way for me to physically store the .html files for my
components separated (i.e. in a different folder structure) from the .html
files for my pages and still be able to have all these components/pages free
of any specification files?

 

How can I use components that are stored in different folders (to keep them
organized), reference them by their component names (without regard for
where they are stored) and still not need the specification files for them?

 

Will there be, in the final version, configuration properties that will
allow you to specify root folders for you page and component resources
(.html and .properties files) separately? 

 

I'm not great at explaining things, but I hope I was clear enough. Maybe I'm
missing something, so please help me understand.

 

Thanks,

Denis Souza

 

Reply via email to