Robert,
Thanks for the suggestion. I actually got it working. Turns out
you can init the library page with the prefix:
(MySharedPage)cycle.getPage("sharedWebUtils:MySharedPage");
Any yes, the declaration in the .application file doesn't seem to be
needed.
Seems to work fine. :-)
e.
On Jul 18, 2005, at 11:48 AM, Robert Zeigler wrote:
Hi Eric, not 100% sure on this, myself, since I've not dealt with this
yet (though I eventually will, I'm sure. :) But, from what I could
glean
from the source surrounding INamespace, pagelink, etc., I'd suggest
that
you first remove the page declaration in the .application file.
Then, do
something like:
String pageName =
this.getNamespace().construcQualifiedName("MySharedPage");
MySharedPage nextPage = (MySharedPage) cycle.getPage(pageName);
Let me know if that works for you, since, like I mentioned, this is
probably something I will be needing to do in the future. :)
Robert
Eric Schneider wrote:
Hi,
I'm having a heck of time moving a page (.java, .html, .page) into a
shared library.
In my app's listener call, it throws a DocumentParseException on this
line:
MySharedPage nextPage = (MySharedPage)cycle.getPage("MySharedPage");
"Could not parse specification context:/com/myco/shared/tapestry/
pages/MySharedPage.page."
My shared library is bundled in a .jar file and dropped in the
application's WEB-INF/lib directory. The .page file is indeed
included
in that .jar and the paths are correct.
I have a declaration in my .library file, tho I'm not sure if it's
required because it seems you need to add a corresponding declaration
in the .application file anyway so that it's included in the
application's namespace.
<page name="MySharedPage" specification-path="pages/
MySharedPage.page"/>
In my .application file:
<page name="MySharedPage" specification-path="/com/myco/shared/
tapestry/pages/MySharedPage.page"/>
<library id="sharedWebUtils" specification-path="/com/myco/shared/
tapestry/SharedWebUtils.library"/>
All components in the library work perfectly, but obviously
components
are reference differently. I don't believe something like this
will work:
(MySharedPage)cycle.getPage("sharedWebUtils:MySharedPage");
Maybe someone can tell me what gear I'm missing here?
Thanks,
Eric
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: tapestry-user-
[EMAIL PROTECTED]
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]