T5 I need to be able to dynamically render components

2007-05-30 Thread Jonathan Glanz
All, below is a sample of what I'd like to be able to do, but I can't seem
to figure out a way to make it work

 

t:loop source=widgets value=widget

div t:type=prop:viewElementType/

/t:loop

 

Is there a way to do this or a binding that would do this?  Basically I need
a way to dynamically instantiate components at runtime.

 

-thx, Jon



Re: T5 class reloading

2007-05-30 Thread Ted Steen

Somewhere in the documentation it says that all pages are components,
so i guess that all components and pages (that are special kinds of
components) will automatically reload.


2007/5/29, Martin Grotzke [EMAIL PROTECTED]:

Hi,

is the class reloading in T5 limited to component classes as
described at
http://tapestry.apache.org/tapestry5/tapestry-core/guide/component-classes.html:
However, class reloading only applies to component classes.

Although, at
http://tapestry.apache.org/tapestry5/tapestry-core/guide/reload.html is
written that In Tapestry 5, page and component classes will
automatically reload when changed...

Of course, the latter case would be really, really cool and appreciated,
but if so: how do I get it to work?

Thx  cheers,
Martin







--
/ted

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: dojo dialog to populate portion of form and submit

2007-05-30 Thread Paul Stanton
I've just tried a javascript writeback hack (trying to keep it 
tapestry-ish, yet it's a hack for sure)


basically, the dialog's form elements are Any's so they populate 
correctly, but don't submit to tapestry. then when the submit button is 
clicked they Any's values are sucked into some hidden (TextField with 
display:none in css) and the form is submitted.


I figured this would take advantage of the ajax parts that work for me, 
and avoid what isn't working. the problem with this is that:
1. I need to make use of a converter to make sure that tapestry can find 
the appropriate object on rewind; i can't figure out how to use a 
converter on a plain old TextField or Hidden
2. If there are validation issues with the user input, the Any component 
needs to receive the validator message etc, not the invisible TextField.


I'd love to be able to change my border component so that the 
LinkSubmit's can sit outside of the form (substitute them with something 
else) so that pages can define their own forms and where they begin/end, 
however that in it's self will be a hack and it means changing ten pages 
to include a hack vs changing 1 page to include a hack (if i can hack 
through this dialog issue).


Any suggestions welcome. Paul.

Paul Stanton wrote:

4.1.1

Firstly, I'm pretty sure what I'm trying to do is not possible, so 
read on with that in mind.


My border component defines my form. This is necessary because I have 
a tabbed structure where the tabs are LinkSubmit's and need to be 
associated with a Form.


My page has part of the form content always displayed, normally 
without ajax or anything dynamic. This part is a list of elements with 
checkboxes to enable/disable.


When clicking on an element in the list, a dojo Dialog is displayed 
containing a previously existant yet hidden portion of the form to 
edit the attributes of the element along with a LinkSubmit to submit 
the whole form (border form) when the user is done.


Note that I must continue the existing border's form as the dialog 
code needs to sit within the border, otherwise it would fall outside 
of the html element.


I can't for the life of me get this to work. I think because the 
Dialog is re-rendered (updateComponent) the dialogs portion of the 
form is essentially detached from the border forms request cycle. No 
matter what I enter in the dialog, nothing comes back to the listener 
when the form is submitted.


Is what I'm trying to do possible, or do I need to rip apart my border 
component so that I can embed a separate form in the dialog?


Thanks, Paul.


-
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]



Re: T5 class reloading

2007-05-30 Thread Martin Grotzke
On Wed, 2007-05-30 at 13:44 +0700, Ted Steen wrote:
 Somewhere in the documentation it says that all pages are components,
 so i guess that all components and pages (that are special kinds of
 components) will automatically reload.
Then the question is what's required to get it to work.

For me changed classes are not picked up automatically, when running
mvn jetty6:run...
If it's working for you, what's your setup, or did you do anything
special to support class reloading? Is it connected with a context
reload of your servlet container (what AFAICS should not be necessary)?

Thx  cheers,
Martin


 
 
 2007/5/29, Martin Grotzke [EMAIL PROTECTED]:
  Hi,
 
  is the class reloading in T5 limited to component classes as
  described at
  http://tapestry.apache.org/tapestry5/tapestry-core/guide/component-classes.html:
  However, class reloading only applies to component classes.
 
  Although, at
  http://tapestry.apache.org/tapestry5/tapestry-core/guide/reload.html is
  written that In Tapestry 5, page and component classes will
  automatically reload when changed...
 
  Of course, the latter case would be really, really cool and appreciated,
  but if so: how do I get it to work?
 
  Thx  cheers,
  Martin
 
 
 
 
 
 
-- 
Martin Grotzke
http://www.javakaffee.de/blog/


signature.asc
Description: This is a digitally signed message part


Re: T5 class reloading

2007-05-30 Thread Francois Armand
Le mercredi 30 mai 2007 à 07:28 +, Martin Grotzke a écrit :
 For me changed classes are not picked up automatically, when running
 mvn jetty6:run...
 If it's working for you, what's your setup, or did you do anything
 special to support class reloading? Is it connected with a context
 reload of your servlet container (what AFAICS should not be necessary)?

Well... I encounter some strange behaviour with mvn jetty:run and class
reloading. It works perfectly at my work, and jetty fire some exception
about unimplemented class reloading functionality in fresh install of
eclipse 3.2 at home.
 
So, the way that seems to just work is to use jetty 5 + jetty launcher
plugin, as show in the tutorial
( http://tapestry.apache.org/tapestry5/t5-tutorial.pdf ), and let mvn
apart for that task.

If some one has a procedure to have mvn jetty:run + jetty 6 (0 or 1) +
class/template reloading work, or just can explain what factors make it
work or not, I will be glad to know them.

Hope it will help, 
Francois


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: T5 - Service injection and ioc

2007-05-30 Thread Blackwings

The only error I have is :

#  java.lang.ClassNotFoundException
caught an exception while obtaining a class file for papo.pages.Start

exception
   java.lang.RuntimeException: Error obtaining injected value for
field papo.pages.Start._userService: No service implements the
interface papo.ioc.services.UserService.

I tried to happen in AppModule the following lines and discard the
UserModule class :

public static void bind(ServiceBinder binder) {
binder.bind(UserService.class, UserServiceImpl.class);
}

to use the autobuilding services, but I still have the same error.

What about package names? In my web.xml I declared :
context-param
!-- The only significant configuration for Tapestry 5, this 
informs Tapestry
of where to look for pages, components and mixins. --
param-nametapestry.app-package/param-name
param-valuepapo/param-value
/context-param

but maybe I have to put my services/modules classes in a specific
package rather than my papo.ioc.services ?



2007/5/30, Davor Hrg [EMAIL PROTECTED]:

I tried @Inject Session session; but it didn't work.


you probably have an error in log from tapestry demanding for the field to
be private...

try:
@Inject private Session session;

Davor Hrg

On 5/30/07, Joshua Jackson [EMAIL PROTECTED] wrote:

 I found that the @Service annotation is not available anymore in
 tapestry-core-5.0.4

 So how do I inject a service that was created by the AppModule into my web
 Page/Component ?

 Let's say the Session service created by the tapestry-hibernate module.

 I tried @Inject Session session; but it didn't work.

 Have I missed on something?


 Thanks in advance.

 On 5/30/07, Howard Lewis Ship [EMAIL PROTECTED] wrote:
  You don't need the MANIFEST.MF.
 
  You do need to name your module correctly, it should be AppModule.  The
  documention is *very clear* on the naming for that.
 
  Also, you should consider letting Tapestry IoC inject the Log (
  org.apache.commons.logging.Log) for your service; cleans up a lot of
 code
  that way.
 
  This will be

 --
 YM!: thejavafreak
 Blog: http://www.nagasakti.or.id/roller/joshua/

 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]






--
Michael Bernagou
Java Developper

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: T5 - Service injection and ioc

2007-05-30 Thread Blackwings

Ok I found the problem and it was not my code but the packages!!
Services and modules have to be in papo.services, if I declared in web.xml
tapestry.app-package with papo.

But I was able to declare my builder in AppModule but I still doesn't
achieve to create my own module, in the same package, whatever I create a
builder or use the binder or declare the module in the manifest...

When I copied the builder or binder from my module to AppModule, it works.

package papo.services;

public final class UserModule {
 public UserService buildUserService() {
   return new UserServiceImpl();
 }
}



2007/5/30, Blackwings [EMAIL PROTECTED]:

The only error I have is :

#  java.lang.ClassNotFoundException
caught an exception while obtaining a class file for papo.pages.Start

exception
java.lang.RuntimeException: Error obtaining injected value for
field papo.pages.Start._userService: No service implements the
interface papo.ioc.services.UserService.

I tried to happen in AppModule the following lines and discard the
UserModule class :

public static void bind(ServiceBinder binder) {
 binder.bind(UserService.class, UserServiceImpl.class);
}

to use the autobuilding services, but I still have the same error.

What about package names? In my web.xml I declared :
context-param
!-- The only significant configuration for Tapestry 5,

this informs Tapestry

of where to look for pages, components and mixins.

--

param-nametapestry.app-package/param-name
param-valuepapo/param-value
/context-param

but maybe I have to put my services/modules classes in a specific
package rather than my papo.ioc.services ?



2007/5/30, Davor Hrg [EMAIL PROTECTED]:
 I tried @Inject Session session; but it didn't work.
 

 you probably have an error in log from tapestry demanding for the field

to

 be private...

 try:
 @Inject private Session session;

 Davor Hrg

 On 5/30/07, Joshua Jackson [EMAIL PROTECTED] wrote:
 
  I found that the @Service annotation is not available anymore in
  tapestry-core-5.0.4
 
  So how do I inject a service that was created by the AppModule into my

web

  Page/Component ?
 
  Let's say the Session service created by the tapestry-hibernate

module.

 
  I tried @Inject Session session; but it didn't work.
 
  Have I missed on something?
 
 
  Thanks in advance.
 
  On 5/30/07, Howard Lewis Ship [EMAIL PROTECTED] wrote:
   You don't need the MANIFEST.MF.
  
   You do need to name your module correctly, it should be

AppModule.  The

   documention is *very clear* on the naming for that.
  
   Also, you should consider letting Tapestry IoC inject the Log (
   org.apache.commons.logging.Log) for your service; cleans up a lot of
  code
   that way.
  
   This will be
 
  --
  YM!: thejavafreak
  Blog: http://www.nagasakti.or.id/roller/joshua/
 
  -
  To unsubscribe, e-mail: [EMAIL PROTECTED]
  For additional commands, e-mail: [EMAIL PROTECTED]
 
 



--
Michael Bernagou
Java Developper




--
Michael Bernagou
Java Developper


Re: T4.1.1 - ComponentClass and Component annotation question

2007-05-30 Thread Christian Dutaret

http://jira.opensymphony.com/browse/OGNL-84

2007/5/29, Jesse Kuhnert [EMAIL PROTECTED]:


OGNL errors?  Hmmm.   When you do file them the best place is here:

http://jira.opensymphony.com/browse/OGNL

Please do file them when you get a chance as I'm not as comfortable making
a
release knowing they exist.

On 5/29/07, Christian Dutaret [EMAIL PROTECTED] wrote:

 +1

 Just tried an upgrade from 4.1.1 (large app) and it went more smoothly
 than
 I expected. A few OGNL and EventListener issues here and there, not too
 difficult to fix.
 When I have time, I'll post the OGNL issues I noticed (all related to
the
 way expressions like prop1.prop2[index] are handled - quick fix
replace
 with prop1.getProp2(index))
 So whenever you start the vote, count me in ;-)

 2007/5/28, Jesse Kuhnert [EMAIL PROTECTED]:
 
  I think I'm going to start a vote to release it this week,  so if that
  goes
  well possibly this week.
 
  On 5/28/07, Jan Vissers [EMAIL PROTECTED] wrote:
  
   And...
   any idea when T4.1.2 will be released. I'm currently (re)evaluating
  T4.1+
   as one of our predominant (web)frameworks - currently we already use
   T3/T4.0.2 quite frequently.
  
   -J.
  
Ok, thanks
   
But what does this mean exactly, in terms of how I specify the
   @Component?
Should I (still) use: @Component(type=components/Feedback)
or something different?
   
Suppose I would have bundled these components into a Tapestry
 library
  -
would that have changed something, or is this not comparable from
  using
   a
Component as part of your application, so without libraries?
   
This 4.1.2-SNAPSHOT contains a fix, for something I guess - right?
Can I use 4.1.2-SNAPSHOT with JDK1.4, provided I decide not to use
annotations?
   
Thanks again
-J.
   
Use 4.1.2-SNAPSHOT.
   
On 5/28/07, Jan Vissers [EMAIL PROTECTED] wrote:
   
Anybody have a clue for me?
   
-J.
   
 First...

 I had some components specified in a directory
(ctxroot/components).
A
 couple of components had an empty component specification
file
(.jwc)
-
 so I tried to use @ComponentClass on the component so I don't
 need
the
 .jwc file any longer.

 A page class in my application first used the .jwc'd component
  like
so:

   @Component(type=components/Feedback)
   public abstract Feedback getFeedback();

 Question:

 How should I specify @ComponentClass and/or @Component
 annotation,
   so
the
 component is properly spotted when the page loads? - currently
I
   have
been
 unable to. Remember the ctxroot/components folder only
 contains
   the
 component's html template.

 Thanks,
 -J.



  
-
 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]
   
   
   
   
--
Jesse Kuhnert
Tapestry/Dojo team member/developer
   
Open source based consulting work centered around
dojo/tapestry/tacos/hivemind. http://blog.opencomponentry.com
   
   
   
   
   
 -
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]
  
  
 
 
  --
  Jesse Kuhnert
  Tapestry/Dojo team member/developer
 
  Open source based consulting work centered around
  dojo/tapestry/tacos/hivemind. http://blog.opencomponentry.com
 




--
Jesse Kuhnert
Tapestry/Dojo team member/developer

Open source based consulting work centered around
dojo/tapestry/tacos/hivemind. http://blog.opencomponentry.com



Re: T4.1.x: @Dialog component triggers a lot a javascript errors on scroll after open/close

2007-05-30 Thread Christian Dutaret

https://issues.apache.org/jira/browse/TAPESTRY-1527

2007/5/29, Jesse Kuhnert [EMAIL PROTECTED]:


Can you file a bug for this ?

On 5/29/07, Christian Dutaret [EMAIL PROTECTED] wrote:

 Hi all,

 I've been playing with the @Dialog component and EventListener
 annotations,
 and I am facing a problem with the dojo js:

 - the @Dialog component is initialized as hidden
 - A user clicks on a link, which triggers an EventListener, which
updates
 a
 component that wraps the @Dialog and makes it visible
 - within the Dialog, a Close button is displayed. When the user clicks
 on
 it, it triggers the EventListener again, the wrapper component is
updated
 and the Dialog is set back to hidden.

 Everything works as expected, but once the Dialog has been opened then
 closed once, every scroll event on the page triggers js errors.
 on FF2.0 : node has no properties on line 96 in dojo.js
 on IE7 : offsetWidth is null or is not an object (freely translated
from
 french)

 Tried it on 4.1.1 and latest 4.1.2 snapshot : exact same behavior.

 my HTML template:

 span jwcid=[EMAIL PROTECTED]
 div jwcid=[EMAIL PROTECTED] hidden=ognl:hidden
backgroundColor=blue
 div style=background-color: white; border-width: 1px; width:
 600px; height: 400px;DIV contentbr /
 forminput type=button
 onclick=someJsThatEventuallyTriggersTheEventListener(); value=Close
 //form
 /div
 /div
 /span


 my page class:

 @InitialValue(true)
 public abstract void setHidden(boolean value);

 @EventListener(elements = dialwrapper, events =
someCustomJsEvent,
 submitForm = hiddenFormWhichUpdatesSelectedAnnounceId)
 public void selectAnnounce(IRequestCycle cycle, BrowserEvent event)
{
 setHidden(getSelectedAnnounceId() == null);
 cycle.getResponseBuilder().updateComponent(dialwrapper);
 }

 Thx
 Ch.




--
Jesse Kuhnert
Tapestry/Dojo team member/developer

Open source based consulting work centered around
dojo/tapestry/tacos/hivemind. http://blog.opencomponentry.com



URGENT: Where are hivemind 1.1.1 sources

2007-05-30 Thread Jan Vissers

Hi,

I'm desperately looking for the sources of hivemind 1.1.1
I can find a tagged 1.1 version, and the trunk is 1.2.1 - or so the pom 
suggests


Where is 1.1.1?

Thanks,
-J.

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: URGENT: Where are hivemind 1.1.1 sources

2007-05-30 Thread Robin Ericsson

On 5/30/07, Jan Vissers [EMAIL PROTECTED] wrote:

Hi,

I'm desperately looking for the sources of hivemind 1.1.1
I can find a tagged 1.1 version, and the trunk is 1.2.1 - or so the pom
suggests

Where is 1.1.1?


Included in the distribution tarball?

--
   regards,
   Robin

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



T4.1.2 How to generate URL to the listener method

2007-05-30 Thread Denis Burlaka

Hi, All.

How can I generate URL for the listener method in my component? I need that
for my javascript function that must send async request to that URL. I can't
use DirectLink component because the element that will send request is
generated dynamically in another javascript function on the client side.

Thanks.


4.1.2 Cometd Implimentation

2007-05-30 Thread Craig Spry
I'm looking at adding cometd type functionality to the tapestry
4.1.2-snapshot application that I'm currently developing.  I would like
to do it as follows:

Have only one cometd subscription per page.  This would be bound to a
javascript function that would have the updates sent to it, much like
XHR works at the moment, except in reverse.

Then in the Java code for that page I would have a thread that would
have code in it that would look something like this:

private void poll()
{
while(true)
{
Thread.sleep(1000)
{
if(some_condition)
{

MyTapestryCometdClient.updateComponent('component_id');
}
}
}
} 

Where MyTapestryCometdClient would be my implementation to send out the
cometd request to all the waiting javascript functions. 

I'm going to use Jetty's implementation of cometd.
 
What I would like to know is what I'm trying to achieve feasible, can
Tapestry 4.1.2 even be made work with comet?

Has anyone else already got Tapestry to work with cometd?

Or is there a better way to get events from the server to a waiting web
page that doesn't involve polling?

If no one has and I do manage to get it to work, would anyone else be
interested in how I got it to work?

Thanks,
Craig Spry

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: HTML tags....such as Publisher or Front page editor.....

2007-05-30 Thread Joshua Jackson

You should have this
html xmlns:t=http://tapestry.apache.org/schema/tapestry_5_0_0.xsd;

on your html page.

I assume that's what cause the problems

On 5/30/07, erwin_br [EMAIL PROTECTED] wrote:


I am from brazil... I am study tapestry and there is something that i could
understand.
i would like to construct a web page using front page or publisher and put
into the components tapestry but don´t work
EX: i do the screnncast 5...no problem work fine.but if i edit the
start.html with publisher or front page and put some html tags then when i
run again don´t work...seems to be the tapestry don´t accept the tags
html...do you now how i fix this problem?
--
View this message in context: 
http://www.nabble.com/HTML-tagssuch-as-Publisher-or-Front-page-editor.-tf3840106.html#a10872829
Sent from the Tapestry - User mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]





--
YM!: thejavafreak
Blog: http://www.nagasakti.or.id/roller/joshua/

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: HTML tags....such as Publisher or Front page editor.....

2007-05-30 Thread #Cyrille37#

erwin_br a écrit :

i would like to construct a web page using front page or publisher and put
into the components tapestry but don´t work
EX: i do the screnncast 5...no problem work fine.but if i edit the
start.html with publisher or front page and put some html tags then when i
run again don´t work...

Hello,
What is do not work ? Give more detail on the error.



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



URGENT: T4.1.1 on Oracle OC4J 9.0.4, 10.1.2.xxx - Missing classpath resource '/dojo' issue

2007-05-30 Thread Jan Vissers

Hi,

I'm starting a new project for a customer of ours and want to use 
Tapestry 4.1.1 on Oracle's J2EE container - OC4J.
Having tested various aspects of this T version on 10.1.3 - I'm pretty 
keen on using this version, however there are issues...


Firstly I ran into a known issue with Hivemind's URLResource class on 
OC4J 9.0.4/10.1.2.xxx.
I used a proposed hack to fix this issue. But now when I drop a Shell 
component on a form, I get this error:


Caused by: org.apache.hivemind.ApplicationRuntimeException: Missing classpath 
resource '/dojo/'. [classpath:/org/apache/tapestry/html/Shell.jwc, line 179, 
column 61]
at 
org.apache.tapestry.asset.ClasspathAssetFactory.createAbsoluteAsset(ClasspathAssetFactory.java:61)
at 
$AssetFactory_112dd0124f3.createAbsoluteAsset($AssetFactory_112dd0124f3.java)
at 
org.apache.tapestry.asset.AssetSourceImpl.findAsset(AssetSourceImpl.java:84)
at $AssetSource_112dd0124a7.findAsset($AssetSource_112dd0124a7.java)
at 
org.apache.tapestry.pageload.PageLoader.convertAsset(PageLoader.java:695)
at 
org.apache.tapestry.pageload.PageLoader.addAssets(PageLoader.java:670)
at 
org.apache.tapestry.pageload.PageLoader.constructComponent(PageLoader.java:415)
at 
org.apache.tapestry.pageload.PageLoader.createImplicitComponent(PageLoader.java:478)
at 
$IPageLoader_112dd0124a3.createImplicitComponent($IPageLoader_112dd0124a3.java)
at 
$IPageLoader_112dd0124a4.createImplicitComponent($IPageLoader_112dd0124a4.java)
at 
org.apache.tapestry.services.impl.ComponentTemplateLoaderLogic.createImplicitComponent(ComponentTemplateLoaderLogic.java:218)
at 
org.apache.tapestry.services.impl.ComponentTemplateLoaderLogic.process(ComponentTemplateLoaderLogic.java:172)
at 
org.apache.tapestry.services.impl.ComponentTemplateLoaderLogic.process(ComponentTemplateLoaderLogic.java:111)
at 
org.apache.tapestry.services.impl.ComponentTemplateLoaderLogic.loadTemplate(ComponentTemplateLoaderLogic.java:88)
at 
org.apache.tapestry.services.impl.ComponentTemplateLoaderImpl.loadTemplate(ComponentTemplateLoaderImpl.java:61)
at 
$ComponentTemplateLoader_112dd0124ad.loadTemplate($ComponentTemplateLoader_112dd0124ad.java)
at 
org.apache.tapestry.pageload.PageLoader.loadTemplateForComponent(PageLoader.java:637)
at org.apache.tapestry.BaseComponent.readTemplate(BaseComponent.java:77)
at org.apache.tapestry.BaseComponent.finishLoad(BaseComponent.java:107)
at $Exception_5.finishLoad($Exception_5.java)
at 
org.apache.tapestry.pageload.PageLoader.constructComponent(PageLoader.java:425)
at org.apache.tapestry.pageload.PageLoader.loadPage(PageLoader.java:600)
at $IPageLoader_112dd0124a3.loadPage($IPageLoader_112dd0124a3.java)
at $IPageLoader_112dd0124a4.loadPage($IPageLoader_112dd0124a4.java)
at org.apache.tapestry.pageload.PageSource.getPage(PageSource.java:119)
at $IPageSource_112dd012406.getPage($IPageSource_112dd012406.java)
at 
org.apache.tapestry.engine.RequestCycle.loadPage(RequestCycle.java:248)
at 
org.apache.tapestry.engine.RequestCycle.getPage(RequestCycle.java:235)
at 
org.apache.tapestry.error.ExceptionPresenterImpl.presentException(ExceptionPresenterImpl.java:42)
... 30 more


Can somebody enlighten me what's wrong here and whether or not this is a 
known issue?
I sure as * hope I don't have to hack my way around this (probably 
Oracle related) issue also...


Thanks,
-J.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Tapestry 3 and Valid XHTML Forms (generated Script tag)

2007-05-30 Thread Andrew Ingram

Thanks Jonathan,

I'm down to just one tapestry-generated validation error now.

I'm still getting the language attribute on script tags (example below), 
i've looked through the tapestry source and the scripting stuff seems a 
bit complicated, even if I tell the component to not use client side 
scripting it still generates a small amount of script (used for focusing 
the text input).


I'm interested in knowing two things:
1) Where in tapestry is the script tag written and how can I overwrite 
it to not use the language attribute?

2) Can I make a validfield generate no javascript whatsoever?

Example output:

script language=JavaScript type=text/javascript 
src=/app?service=assetamp;sp=S%2Forg%2Fapache%2Ftapestry%2Fvalid%2FValidator.jsamp;sp=S3dfc7ba91240b3bbd49fbb3efe31/script
script language=JavaScript type=text/javascript!--


function validate_SearchField()
{
 var field = document.Form0.SearchField;

 if (field.value.length == 0)
return validator_invalid_field(field, You must enter a value for the search to 
work...);


 if (field.value.length  1)
return validator_invalid_field(field, You must enter at least 1 characters for 
the search to work...);

 return true;
}


window.onload = function ()
{
document.Form0.SearchField.focus();
document.Form0.SearchField.select();
document.Form0.onsubmit = validate_SearchField;
}


Regards,
Andrew Ingram



Jonathan O'Connor wrote:


Andrew,
you will have to roll your own components. The ImageSubmit component 
should be fairly easy. Just copy the source for the ImageSubmit 
component, and then alter the code to avoid outputing a border 
attribute. You can probably also extend from ImageSubmit, and change 
the rendering.


You should be able to do the same with the Form class too.

Sorry I can't be more explicit, but its over a year since I did any 
Tapestry work (all Tap3).

Good luck,
Jonathan O'Connor
XCOM Dublin




__
This email has been scanned by the MessageLabs Email Security System.
For more information please visit http://www.messagelabs.com/email 
__


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: URGENT: T4.1.1 on Oracle OC4J 9.0.4, 10.1.2.xxx - Missing classpath resource '/dojo' issue

2007-05-30 Thread Jan Vissers

Checking the (Tapestry) code:

public IAsset createAbsoluteAsset(String path, Locale locale, Location 
location)

   {
   Resource base = new ClasspathResource(_classResolver, path);
   Resource localized = _localizer.findLocalization(base, locale);

   if (localized == null)
   throw new 
ApplicationRuntimeException(AssetMessages.missingClasspathResource(path),

   location, null);

   return createAsset(localized, location);
   }

_localizer.findLocalization(base, locale);
Returns null for '/dojo' ... why would this happen?

Thanks,
-J.

Jan Vissers wrote:

Hi,

I'm starting a new project for a customer of ours and want to use 
Tapestry 4.1.1 on Oracle's J2EE container - OC4J.
Having tested various aspects of this T version on 10.1.3 - I'm pretty 
keen on using this version, however there are issues...


Firstly I ran into a known issue with Hivemind's URLResource class on 
OC4J 9.0.4/10.1.2.xxx.
I used a proposed hack to fix this issue. But now when I drop a Shell 
component on a form, I get this error:


Caused by: org.apache.hivemind.ApplicationRuntimeException: Missing 
classpath resource '/dojo/'. 
[classpath:/org/apache/tapestry/html/Shell.jwc, line 179, column 61]
at 
org.apache.tapestry.asset.ClasspathAssetFactory.createAbsoluteAsset(ClasspathAssetFactory.java:61) 

at 
$AssetFactory_112dd0124f3.createAbsoluteAsset($AssetFactory_112dd0124f3.java) 

at 
org.apache.tapestry.asset.AssetSourceImpl.findAsset(AssetSourceImpl.java:84) 


at $AssetSource_112dd0124a7.findAsset($AssetSource_112dd0124a7.java)
at 
org.apache.tapestry.pageload.PageLoader.convertAsset(PageLoader.java:695)
at 
org.apache.tapestry.pageload.PageLoader.addAssets(PageLoader.java:670)
at 
org.apache.tapestry.pageload.PageLoader.constructComponent(PageLoader.java:415) 

at 
org.apache.tapestry.pageload.PageLoader.createImplicitComponent(PageLoader.java:478) 

at 
$IPageLoader_112dd0124a3.createImplicitComponent($IPageLoader_112dd0124a3.java) 

at 
$IPageLoader_112dd0124a4.createImplicitComponent($IPageLoader_112dd0124a4.java) 

at 
org.apache.tapestry.services.impl.ComponentTemplateLoaderLogic.createImplicitComponent(ComponentTemplateLoaderLogic.java:218) 

at 
org.apache.tapestry.services.impl.ComponentTemplateLoaderLogic.process(ComponentTemplateLoaderLogic.java:172) 

at 
org.apache.tapestry.services.impl.ComponentTemplateLoaderLogic.process(ComponentTemplateLoaderLogic.java:111) 

at 
org.apache.tapestry.services.impl.ComponentTemplateLoaderLogic.loadTemplate(ComponentTemplateLoaderLogic.java:88) 

at 
org.apache.tapestry.services.impl.ComponentTemplateLoaderImpl.loadTemplate(ComponentTemplateLoaderImpl.java:61) 

at 
$ComponentTemplateLoader_112dd0124ad.loadTemplate($ComponentTemplateLoader_112dd0124ad.java) 

at 
org.apache.tapestry.pageload.PageLoader.loadTemplateForComponent(PageLoader.java:637) 

at 
org.apache.tapestry.BaseComponent.readTemplate(BaseComponent.java:77)
at 
org.apache.tapestry.BaseComponent.finishLoad(BaseComponent.java:107)

at $Exception_5.finishLoad($Exception_5.java)
at 
org.apache.tapestry.pageload.PageLoader.constructComponent(PageLoader.java:425) 

at 
org.apache.tapestry.pageload.PageLoader.loadPage(PageLoader.java:600)

at $IPageLoader_112dd0124a3.loadPage($IPageLoader_112dd0124a3.java)
at $IPageLoader_112dd0124a4.loadPage($IPageLoader_112dd0124a4.java)
at 
org.apache.tapestry.pageload.PageSource.getPage(PageSource.java:119)

at $IPageSource_112dd012406.getPage($IPageSource_112dd012406.java)
at 
org.apache.tapestry.engine.RequestCycle.loadPage(RequestCycle.java:248)
at 
org.apache.tapestry.engine.RequestCycle.getPage(RequestCycle.java:235)
at 
org.apache.tapestry.error.ExceptionPresenterImpl.presentException(ExceptionPresenterImpl.java:42) 


... 30 more


Can somebody enlighten me what's wrong here and whether or not this is 
a known issue?
I sure as * hope I don't have to hack my way around this (probably 
Oracle related) issue also...


Thanks,
-J.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]





--
Cumquat Information Technology
De Dreef 19
3706 BR Zeist
T +31 (0)30 - 6940490
F +31 (0)30 - 6940499
W http://www.cumquat.nl

E [EMAIL PROTECTED]
M +31 6 51 169 556
B http://www.cumquat.nl/technology_atom10.xml



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: URGENT: T4.1.1 on Oracle OC4J 9.0.4, 10.1.2.xxx - Missing classpath resource '/dojo' issue

2007-05-30 Thread Jan Vissers

Digging deeper, and deeper...

In DefaultClassResolver this method:

public URL getResource(String name)
   {
   String stripped = removeLeadingSlash(name);

   URL result = _loader.getResource(stripped);

   return result;
   }

returns null for 'dojo/' ...
smells like a class loading issue, doesn't it

any ideas?
-J.

Jan Vissers wrote:

Checking the (Tapestry) code:

public IAsset createAbsoluteAsset(String path, Locale locale, Location 
location)

   {
   Resource base = new ClasspathResource(_classResolver, path);
   Resource localized = _localizer.findLocalization(base, locale);

   if (localized == null)
   throw new 
ApplicationRuntimeException(AssetMessages.missingClasspathResource(path),

   location, null);

   return createAsset(localized, location);
   }

_localizer.findLocalization(base, locale);
Returns null for '/dojo' ... why would this happen?

Thanks,
-J.

Jan Vissers wrote:

Hi,

I'm starting a new project for a customer of ours and want to use 
Tapestry 4.1.1 on Oracle's J2EE container - OC4J.
Having tested various aspects of this T version on 10.1.3 - I'm 
pretty keen on using this version, however there are issues...


Firstly I ran into a known issue with Hivemind's URLResource class on 
OC4J 9.0.4/10.1.2.xxx.
I used a proposed hack to fix this issue. But now when I drop a Shell 
component on a form, I get this error:


Caused by: org.apache.hivemind.ApplicationRuntimeException: Missing 
classpath resource '/dojo/'. 
[classpath:/org/apache/tapestry/html/Shell.jwc, line 179, column 61]
at 
org.apache.tapestry.asset.ClasspathAssetFactory.createAbsoluteAsset(ClasspathAssetFactory.java:61) 

at 
$AssetFactory_112dd0124f3.createAbsoluteAsset($AssetFactory_112dd0124f3.java) 

at 
org.apache.tapestry.asset.AssetSourceImpl.findAsset(AssetSourceImpl.java:84) 


at $AssetSource_112dd0124a7.findAsset($AssetSource_112dd0124a7.java)
at 
org.apache.tapestry.pageload.PageLoader.convertAsset(PageLoader.java:695) 

at 
org.apache.tapestry.pageload.PageLoader.addAssets(PageLoader.java:670)
at 
org.apache.tapestry.pageload.PageLoader.constructComponent(PageLoader.java:415) 

at 
org.apache.tapestry.pageload.PageLoader.createImplicitComponent(PageLoader.java:478) 

at 
$IPageLoader_112dd0124a3.createImplicitComponent($IPageLoader_112dd0124a3.java) 

at 
$IPageLoader_112dd0124a4.createImplicitComponent($IPageLoader_112dd0124a4.java) 

at 
org.apache.tapestry.services.impl.ComponentTemplateLoaderLogic.createImplicitComponent(ComponentTemplateLoaderLogic.java:218) 

at 
org.apache.tapestry.services.impl.ComponentTemplateLoaderLogic.process(ComponentTemplateLoaderLogic.java:172) 

at 
org.apache.tapestry.services.impl.ComponentTemplateLoaderLogic.process(ComponentTemplateLoaderLogic.java:111) 

at 
org.apache.tapestry.services.impl.ComponentTemplateLoaderLogic.loadTemplate(ComponentTemplateLoaderLogic.java:88) 

at 
org.apache.tapestry.services.impl.ComponentTemplateLoaderImpl.loadTemplate(ComponentTemplateLoaderImpl.java:61) 

at 
$ComponentTemplateLoader_112dd0124ad.loadTemplate($ComponentTemplateLoader_112dd0124ad.java) 

at 
org.apache.tapestry.pageload.PageLoader.loadTemplateForComponent(PageLoader.java:637) 

at 
org.apache.tapestry.BaseComponent.readTemplate(BaseComponent.java:77)
at 
org.apache.tapestry.BaseComponent.finishLoad(BaseComponent.java:107)

at $Exception_5.finishLoad($Exception_5.java)
at 
org.apache.tapestry.pageload.PageLoader.constructComponent(PageLoader.java:425) 

at 
org.apache.tapestry.pageload.PageLoader.loadPage(PageLoader.java:600)

at $IPageLoader_112dd0124a3.loadPage($IPageLoader_112dd0124a3.java)
at $IPageLoader_112dd0124a4.loadPage($IPageLoader_112dd0124a4.java)
at 
org.apache.tapestry.pageload.PageSource.getPage(PageSource.java:119)

at $IPageSource_112dd012406.getPage($IPageSource_112dd012406.java)
at 
org.apache.tapestry.engine.RequestCycle.loadPage(RequestCycle.java:248)
at 
org.apache.tapestry.engine.RequestCycle.getPage(RequestCycle.java:235)
at 
org.apache.tapestry.error.ExceptionPresenterImpl.presentException(ExceptionPresenterImpl.java:42) 


... 30 more


Can somebody enlighten me what's wrong here and whether or not this 
is a known issue?
I sure as * hope I don't have to hack my way around this 
(probably Oracle related) issue also...


Thanks,
-J.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]







--
Cumquat Information Technology
De Dreef 19
3706 BR Zeist
T +31 (0)30 - 6940490
F +31 (0)30 - 6940499
W http://www.cumquat.nl

E [EMAIL PROTECTED]
M +31 6 51 169 556
B http://www.cumquat.nl/technology_atom10.xml



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL 

Anyone can answer this?

2007-05-30 Thread Joseph Kobe
Hi,I'm new to Tapestry and was making a search on google to find out some more 
about what people are saying about it but came across this post by Kent Tong- 
http://www.nabble.com/Problem-loading-dynamic-image-using-ajax-tf3805423.htmlHas
 this Tapestry book author, high profile user and commiter deflected to 
Wicket?This begs the question what attracted him to Wicket? I've heard recently 
many, many positivethings about Wicket and I'm tempted to go have a look at it 
instead.Does anyone care to give some comparisons?Regards,Joseph
_
http://www.live.com/?mkt=nl-nl
Live.nl

Re: HTML tags....such as Publisher or Front page editor.....

2007-05-30 Thread erwin_br

Ex: This wokr fine
html xmlns:t=http://tapestry.apache.org/schema/tapestry_5_0_0.xsd;
head
titlemusiclib Start Page/title
/head
body
table t:type=grid rowsPerPage=10 pagerPosition=both
source=tracks
t:parameter name=ratingCell
 
/t:parameter
/table
/body
/html

But if i edit on publish or front page like this:
html xmlns:t=http://tapestry.apache.org/schema/tapestry_5_0_0.xsd;
head
titlemusiclib Start Page/title
/head
FRAMESET COLS=30%, 70%
FRAME SRC=coluna1.html NORESIZE SCROLLING=YES
 frameset ROWS=20%, 80%
FRAME SRC=linha1.html NORESIZE SCROLLING=NO
   FRAME SRC=linha2.html NORESIZE SCROLLING=NO
/frameset
body
/body
/html
I get this error!! 
An unexpected application exception has occurred.

* org.apache.tapestry.ioc.internal.util.TapestryException
  Failure parsing template context:WEB-INF/Start.html: Attribute name
NORESIZE associated with an element type FRAME must be followed by the '
= ' character.

  location
  context:WEB-INF/Start.html, line 6, column 40
  1 html
xmlns:t=http://tapestry.apache.org/schema/tapestry_5_0_0.xsd;
  2 head
  3 titlemusiclib Start Page/title
  4 /head
  5 FRAMESET COLS=30%, 70%
  6 FRAME SRC=coluna1.html NORESIZE SCROLLING=YES
  7 frameset ROWS=20%, 80%
  8 FRAME SRC=linha1.html NORESIZE SCROLLING=NO
  9 FRAME SRC=linha2.html NORESIZE SCROLLING=NO
  10/frameset
  11body BACKGROUND=paper.gif BGCOLOR=#FF TEXT=#00
LINK=#FF VLINK=#FF66FF ALINK=#FF

* org.xml.sax.SAXParseException
  Attribute name NORESIZE associated with an element type FRAME must
be followed by the ' = ' character.
-- 
View this message in context: 
http://www.nabble.com/HTML-tagssuch-as-Publisher-or-Front-page-editor.-tf3840106.html#a10873425
Sent from the Tapestry - User mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: HTML tags....such as Publisher or Front page editor.....

2007-05-30 Thread erwin_br

Ex: This wokr fine
html xmlns:t=http://tapestry.apache.org/schema/tapestry_5_0_0.xsd;
head
titlemusiclib Start Page/title
/head
body
table t:type=grid rowsPerPage=10 pagerPosition=both
source=tracks
t:parameter name=ratingCell
 
/t:parameter
/table
/body
/html

But if i edit on publish or front page like this:
html xmlns:t=http://tapestry.apache.org/schema/tapestry_5_0_0.xsd;
head
titlemusiclib Start Page/title
/head
FRAMESET COLS=30%, 70%
FRAME SRC=coluna1.html NORESIZE SCROLLING=YES
 frameset ROWS=20%, 80%
FRAME SRC=linha1.html NORESIZE SCROLLING=NO
   FRAME SRC=linha2.html NORESIZE SCROLLING=NO
/frameset
body
/body
/html
I get this error!!
An unexpected application exception has occurred.

* org.apache.tapestry.ioc.internal.util.TapestryException
  Failure parsing template context:WEB-INF/Start.html: Attribute name
NORESIZE associated with an element type FRAME must be followed by the '
= ' character.

  location
  context:WEB-INF/Start.html, line 6, column 40
  1 html
xmlns:t=http://tapestry.apache.org/schema/tapestry_5_0_0.xsd;
  2 head
  3 titlemusiclib Start Page/title
  4 /head
  5 FRAMESET COLS=30%, 70%
  6 FRAME SRC=coluna1.html NORESIZE SCROLLING=YES
  7 frameset ROWS=20%, 80%
  8 FRAME SRC=linha1.html NORESIZE SCROLLING=NO
  9 FRAME SRC=linha2.html NORESIZE SCROLLING=NO
  10 /frameset
  11 body BACKGROUND=paper.gif BGCOLOR=#FF TEXT=#00
LINK=#FF VLINK=#FF66FF ALINK=#FF

* org.xml.sax.SAXParseException
  Attribute name NORESIZE associated with an element type FRAME must
be followed by the ' = ' character.
-- 
View this message in context: 
http://www.nabble.com/HTML-tagssuch-as-Publisher-or-Front-page-editor.-tf3840106.html#a10873429
Sent from the Tapestry - User mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: HTML tags....such as Publisher or Front page editor.....

2007-05-30 Thread #Cyrille37#

erwin_br a écrit :

FRAME SRC=coluna1.html NORESIZE SCROLLING=YES
  
* org.apache.tapestry.ioc.internal.util.TapestryException

  Failure parsing template context:WEB-INF/Start.html: Attribute name
NORESIZE associated with an element type FRAME must be followed by the '
= ' character.
  

The parser say that NORESIZE is not a valid XML Attribute.
You can have a try like :

FRAME SRC=coluna1.html NORESIZE=NORESIZE SCROLLING=YES

Cyrille.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Tables, Forms and Ajax

2007-05-30 Thread Jesse Kuhnert

Even if you were somehow able to make it work the way you wanted that
particular application would never work in IE.  IE won't allow you to update
tr elements like that - you can update data within a td element but that's
about it.

On 5/30/07, Paulo Ramos [EMAIL PROTECTED] wrote:


Hi,

I have a table with a DirectLink's that must get more information
from the corresponding line and show them in that line. I am trying to
do that with ajax but the response is rendered inside the corresponding
tag and the id is incremented.
Example: when i try to update the tag with id=2 from line 2 this is
rendered like that:
div id=2
div id=3
bla bla bla
/div
/div

When i tried something more simple that i found in a previous post i
get the same problem. When i click the second line the response is
rendered inside the tr tag including another tr like this:

tr id=therow_0
tr id=therow_1
td 8330 /td
td
a id=DirectLink_1
href=/eLoja/tables/TesteAjaxFor,$DirectLink.sdirect?sp=2updateParts=therow_1
Update therow_1 /a
/td
/tr
/tr
tr id=For_1/

/tr

Can anyone help me?

Thaks,

Paulo Ramos

My example code:

TesteAjaxFor.html :

html
headtitleTeste Tabela/title/head
body jwcid=@Border

div id=content

div id=head_formulario
div class=head_formListagem/div
/div
br
center

table border=1 cellpadding=5

tr jwcid=@For source=ognl:rows value=ognl:row
index=ognl:theIndex
tr jwcid=[EMAIL PROTECTED]
td
span jwcid=@Insert value=ognl:row /span
/td
td
a jwcid=@DirectLink
listener=listener:aListener
async=true
parameters=ognl:{theIndex}
updateComponents=ognl:components.therow.clientId

Update span jwcid=@Insert
value=ognl:components.therow.clientId /span
/a
/td
/tr
/tr

/table


/center
div id=botao
/div
/div
/body
/html



TesteAjaxFor.java :
---
public abstract class TesteAjaxFor extends BasePage implements
PageBeginRenderListener {

@Persist
public abstract String[] getRows();
public abstract void setRows(String[] rows);

public abstract String getRow();
public abstract int getTheIndex();

public void pageBeginRender(PageEvent e)
{
if (getRows() == null){
setRows(new String[] {foo, bar, baz});
}
}

public void aListener(IRequestCycle cycle, int idx)
{
getRows()[idx] =  + (int)(Math.random()*1);
}

}






--
Jesse Kuhnert
Tapestry/Dojo team member/developer

Open source based consulting work centered around
dojo/tapestry/tacos/hivemind. http://blog.opencomponentry.com


Re: T4.1.2 How to generate URL to the listener method

2007-05-30 Thread Jesse Kuhnert

You have to use the corresponding IEngineService service for the type of url
you are generating.. That is how everything in the system (including form
urls) are generated.  Each service has different requirements on the object
type passed in but it's all more or less like:

@InjectObject(service:tapestry.services.DirectService)
public abstract IEngineService getDirectService();

public String getUrl()
{
   String url = getDirectService().getLink(false, new
DirectServiceParameter(/* params */)).getUrl();

   return url;
}

Services can be found in hivedoc linked to off of:

http://tapestry.apache.org/tapestry4.1/tapestry-framework/index.html

On 5/30/07, Denis Burlaka [EMAIL PROTECTED] wrote:


Hi, All.

How can I generate URL for the listener method in my component? I need
that
for my javascript function that must send async request to that URL. I
can't
use DirectLink component because the element that will send request is
generated dynamically in another javascript function on the client side.

Thanks.





--
Jesse Kuhnert
Tapestry/Dojo team member/developer

Open source based consulting work centered around
dojo/tapestry/tacos/hivemind. http://blog.opencomponentry.com


Re: Detecting Tapestry version

2007-05-30 Thread Jesse Kuhnert

Looking at the javascriptdoc (like javadoc for javascript) linked to from
here:

http://tapestry.apache.org/tapestry4.1/javascript/index.html

http://tapestry.apache.org/tapestry4.1/jsdoc/index.html

You can find that the tapestry.version property is a global javascript
reference to the current version of the tapestry client side library you are
using in string form.

Not sure about the java side.  I think there is a static utility method for
that off of Tapestry or TapestryUtils.

On 5/30/07, Geoff Callender [EMAIL PROTECTED] wrote:


What's a simple way in javascript to tell if you're running with 4.0
vs 4.1?
And how would you do it in Java?

Geoff

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]





--
Jesse Kuhnert
Tapestry/Dojo team member/developer

Open source based consulting work centered around
dojo/tapestry/tacos/hivemind. http://blog.opencomponentry.com


Re: 4.1.2 Cometd Implimentation

2007-05-30 Thread Jesse Kuhnert

Yes I'd love to get it going Craig.  I'm sure Alex from Dojo and Greg from
jetty would be happy to see it done as well.

I can make myself available to resolve whatever hurdles need moving / etc in
Tapestry to make this happen.

On 5/30/07, Craig Spry [EMAIL PROTECTED] wrote:


I'm looking at adding cometd type functionality to the tapestry
4.1.2-snapshot application that I'm currently developing.  I would like
to do it as follows:

Have only one cometd subscription per page.  This would be bound to a
javascript function that would have the updates sent to it, much like
XHR works at the moment, except in reverse.

Then in the Java code for that page I would have a thread that would
have code in it that would look something like this:

private void poll()
{
while(true)
{
Thread.sleep(1000)
{
if(some_condition)
{

MyTapestryCometdClient.updateComponent('component_id');
}
}
}
}

Where MyTapestryCometdClient would be my implementation to send out the
cometd request to all the waiting javascript functions.

I'm going to use Jetty's implementation of cometd.

What I would like to know is what I'm trying to achieve feasible, can
Tapestry 4.1.2 even be made work with comet?

Has anyone else already got Tapestry to work with cometd?

Or is there a better way to get events from the server to a waiting web
page that doesn't involve polling?

If no one has and I do manage to get it to work, would anyone else be
interested in how I got it to work?

Thanks,
Craig Spry

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]





--
Jesse Kuhnert
Tapestry/Dojo team member/developer

Open source based consulting work centered around
dojo/tapestry/tacos/hivemind. http://blog.opencomponentry.com


Re: URGENT: T4.1.1 on Oracle OC4J 9.0.4, 10.1.2.xxx - Missing classpath resource '/dojo' issue

2007-05-30 Thread Jesse Kuhnert

Yep.  Sounds like oracle is messing with your classloader.   I love oracle
java software.  I love oracle java software.

On 5/30/07, Jan Vissers [EMAIL PROTECTED] wrote:


Digging deeper, and deeper...

In DefaultClassResolver this method:

public URL getResource(String name)
{
String stripped = removeLeadingSlash(name);

URL result = _loader.getResource(stripped);

return result;
}

returns null for 'dojo/' ...
smells like a class loading issue, doesn't it

any ideas?
-J.

Jan Vissers wrote:
 Checking the (Tapestry) code:

 public IAsset createAbsoluteAsset(String path, Locale locale, Location
 location)
{
Resource base = new ClasspathResource(_classResolver, path);
Resource localized = _localizer.findLocalization(base, locale);

if (localized == null)
throw new
 ApplicationRuntimeException(AssetMessages.missingClasspathResource
(path),
location, null);

return createAsset(localized, location);
}

 _localizer.findLocalization(base, locale);
 Returns null for '/dojo' ... why would this happen?

 Thanks,
 -J.

 Jan Vissers wrote:
 Hi,

 I'm starting a new project for a customer of ours and want to use
 Tapestry 4.1.1 on Oracle's J2EE container - OC4J.
 Having tested various aspects of this T version on 10.1.3 - I'm
 pretty keen on using this version, however there are issues...

 Firstly I ran into a known issue with Hivemind's URLResource class on
 OC4J 9.0.4/10.1.2.xxx.
 I used a proposed hack to fix this issue. But now when I drop a Shell
 component on a form, I get this error:

 Caused by: org.apache.hivemind.ApplicationRuntimeException: Missing
 classpath resource '/dojo/'.
 [classpath:/org/apache/tapestry/html/Shell.jwc, line 179, column 61]
 at
 org.apache.tapestry.asset.ClasspathAssetFactory.createAbsoluteAsset(
ClasspathAssetFactory.java:61)

 at

$AssetFactory_112dd0124f3.createAbsoluteAsset($AssetFactory_112dd0124f3.java)

 at
 org.apache.tapestry.asset.AssetSourceImpl.findAsset(
AssetSourceImpl.java:84)

 at
$AssetSource_112dd0124a7.findAsset($AssetSource_112dd0124a7.java)
 at
 org.apache.tapestry.pageload.PageLoader.convertAsset(PageLoader.java
:695)

 at
 org.apache.tapestry.pageload.PageLoader.addAssets(PageLoader.java:670)
 at
 org.apache.tapestry.pageload.PageLoader.constructComponent(
PageLoader.java:415)

 at
 org.apache.tapestry.pageload.PageLoader.createImplicitComponent(
PageLoader.java:478)

 at

$IPageLoader_112dd0124a3.createImplicitComponent($IPageLoader_112dd0124a3.java)

 at

$IPageLoader_112dd0124a4.createImplicitComponent($IPageLoader_112dd0124a4.java)

 at

org.apache.tapestry.services.impl.ComponentTemplateLoaderLogic.createImplicitComponent
(ComponentTemplateLoaderLogic.java:218)

 at
 org.apache.tapestry.services.impl.ComponentTemplateLoaderLogic.process(
ComponentTemplateLoaderLogic.java:172)

 at
 org.apache.tapestry.services.impl.ComponentTemplateLoaderLogic.process(
ComponentTemplateLoaderLogic.java:111)

 at

org.apache.tapestry.services.impl.ComponentTemplateLoaderLogic.loadTemplate
(ComponentTemplateLoaderLogic.java:88)

 at

org.apache.tapestry.services.impl.ComponentTemplateLoaderImpl.loadTemplate
(ComponentTemplateLoaderImpl.java:61)

 at

$ComponentTemplateLoader_112dd0124ad.loadTemplate($ComponentTemplateLoader_112dd0124ad.java)

 at
 org.apache.tapestry.pageload.PageLoader.loadTemplateForComponent(
PageLoader.java:637)

 at
 org.apache.tapestry.BaseComponent.readTemplate(BaseComponent.java:77)
 at
 org.apache.tapestry.BaseComponent.finishLoad(BaseComponent.java:107)
 at $Exception_5.finishLoad($Exception_5.java)
 at
 org.apache.tapestry.pageload.PageLoader.constructComponent(
PageLoader.java:425)

 at
 org.apache.tapestry.pageload.PageLoader.loadPage(PageLoader.java:600)
 at $IPageLoader_112dd0124a3.loadPage($IPageLoader_112dd0124a3.java)
 at $IPageLoader_112dd0124a4.loadPage($IPageLoader_112dd0124a4.java)
 at
 org.apache.tapestry.pageload.PageSource.getPage(PageSource.java:119)
 at $IPageSource_112dd012406.getPage($IPageSource_112dd012406.java)
 at
 org.apache.tapestry.engine.RequestCycle.loadPage(RequestCycle.java:248)
 at
 org.apache.tapestry.engine.RequestCycle.getPage(RequestCycle.java:235)
 at
 org.apache.tapestry.error.ExceptionPresenterImpl.presentException(
ExceptionPresenterImpl.java:42)

 ... 30 more


 Can somebody enlighten me what's wrong here and whether or not this
 is a known issue?
 I sure as * hope I don't have to hack my way around this
 (probably Oracle related) issue also...

 Thanks,
 -J.


 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]





--
Cumquat Information Technology
De Dreef 19
3706 BR Zeist
T +31 (0)30 - 6940490
F +31 (0)30 - 6940499
W http://www.cumquat.nl

E [EMAIL PROTECTED]
M 

Re: Tables, Forms and Ajax

2007-05-30 Thread Paulo Ramos
Thanks, but i just want to update data within a td element. The tr 
update  is just an example. I tried update data within a div inside a 
td element and it didn't work.


Any ideas?

Paulo Ramos

Jesse Kuhnert escreveu:

Even if you were somehow able to make it work the way you wanted that
particular application would never work in IE.  IE won't allow you to 
update
tr elements like that - you can update data within a td element but 
that's

about it.

On 5/30/07, Paulo Ramos [EMAIL PROTECTED] wrote:


Hi,

I have a table with a DirectLink's that must get more information
from the corresponding line and show them in that line. I am trying to
do that with ajax but the response is rendered inside the corresponding
tag and the id is incremented.
Example: when i try to update the tag with id=2 from line 2 this is
rendered like that:
div id=2
div id=3
bla bla bla
/div
/div

When i tried something more simple that i found in a previous post i
get the same problem. When i click the second line the response is
rendered inside the tr tag including another tr like this:

tr id=therow_0
tr id=therow_1
td 8330 /td
td
a id=DirectLink_1
href=/eLoja/tables/TesteAjaxFor,$DirectLink.sdirect?sp=2updateParts=therow_1 


Update therow_1 /a
/td
/tr
/tr
tr id=For_1/

/tr

Can anyone help me?

Thaks,

Paulo Ramos

My example code:

TesteAjaxFor.html :

html
headtitleTeste Tabela/title/head
body jwcid=@Border

div id=content

div id=head_formulario
div class=head_formListagem/div
/div
br
center

table border=1 cellpadding=5

tr jwcid=@For source=ognl:rows value=ognl:row
index=ognl:theIndex
tr jwcid=[EMAIL PROTECTED]
td
span jwcid=@Insert value=ognl:row /span
/td
td
a jwcid=@DirectLink
listener=listener:aListener
async=true
parameters=ognl:{theIndex}

updateComponents=ognl:components.therow.clientId


Update span jwcid=@Insert
value=ognl:components.therow.clientId /span
/a
/td
/tr
/tr

/table


/center
div id=botao
/div
/div
/body
/html



TesteAjaxFor.java :
---
public abstract class TesteAjaxFor extends BasePage implements
PageBeginRenderListener {

@Persist
public abstract String[] getRows();
public abstract void setRows(String[] rows);

public abstract String getRow();
public abstract int getTheIndex();

public void pageBeginRender(PageEvent e)
{
if (getRows() == null){
setRows(new String[] {foo, bar, baz});
}
}

public void aListener(IRequestCycle cycle, int idx)
{
getRows()[idx] =  + (int)(Math.random()*1);
}

}










smime.p7s
Description: S/MIME Cryptographic Signature


Re: Tables, Forms and Ajax

2007-05-30 Thread Jesse Kuhnert

No I'm not sure based on the data given.   I have an application running
with almost the exact same setup and everything is working fine.  I noticed
that you are setting your rows property on each render - is it consistent ?
Perhaps something is getting confused about changing state.

I would suggest looking into doing some debugging to see what is / isn't
happening :

http://tapestry.apache.org/tapestry4.1/ajax/debugging.html

On 5/30/07, Paulo Ramos [EMAIL PROTECTED] wrote:


Thanks, but i just want to update data within a td element. The tr
update  is just an example. I tried update data within a div inside a
td element and it didn't work.

Any ideas?

Paulo Ramos

Jesse Kuhnert escreveu:
 Even if you were somehow able to make it work the way you wanted that
 particular application would never work in IE.  IE won't allow you to
 update
 tr elements like that - you can update data within a td element but
 that's
 about it.

 On 5/30/07, Paulo Ramos [EMAIL PROTECTED] wrote:

 Hi,

 I have a table with a DirectLink's that must get more information
 from the corresponding line and show them in that line. I am trying to
 do that with ajax but the response is rendered inside the corresponding
 tag and the id is incremented.
 Example: when i try to update the tag with id=2 from line 2 this is
 rendered like that:
 div id=2
 div id=3
 bla bla bla
 /div
 /div

 When i tried something more simple that i found in a previous post
i
 get the same problem. When i click the second line the response is
 rendered inside the tr tag including another tr like this:

 tr id=therow_0
 tr id=therow_1
 td 8330 /td
 td
 a id=DirectLink_1

href=/eLoja/tables/TesteAjaxFor,$DirectLink.sdirect?sp=2updateParts=therow_1

 Update therow_1 /a
 /td
 /tr
 /tr
 tr id=For_1/
 
 /tr

 Can anyone help me?

 Thaks,

 Paulo Ramos

 My example code:

 TesteAjaxFor.html :
 
 html
 headtitleTeste Tabela/title/head
 body jwcid=@Border

 div id=content

 div id=head_formulario
 div class=head_formListagem/div
 /div
 br
 center

 table border=1 cellpadding=5

 tr jwcid=@For source=ognl:rows value=ognl:row
 index=ognl:theIndex
 tr jwcid=[EMAIL PROTECTED]
 td
 span jwcid=@Insert value=ognl:row /span
 /td
 td
 a jwcid=@DirectLink
 listener=listener:aListener
 async=true
 parameters=ognl:{theIndex}

 updateComponents=ognl:components.therow.clientId
 
 Update span jwcid=@Insert
 value=ognl:components.therow.clientId /span
 /a
 /td
 /tr
 /tr

 /table


 /center
 div id=botao
 /div
 /div
 /body
 /html



 TesteAjaxFor.java :
 ---
 public abstract class TesteAjaxFor extends BasePage implements
 PageBeginRenderListener {

 @Persist
 public abstract String[] getRows();
 public abstract void setRows(String[] rows);

 public abstract String getRow();
 public abstract int getTheIndex();

 public void pageBeginRender(PageEvent e)
 {
 if (getRows() == null){
 setRows(new String[] {foo, bar, baz});
 }
 }

 public void aListener(IRequestCycle cycle, int idx)
 {
 getRows()[idx] =  + (int)(Math.random()*1);
 }

 }











--
Jesse Kuhnert
Tapestry/Dojo team member/developer

Open source based consulting work centered around
dojo/tapestry/tacos/hivemind. http://blog.opencomponentry.com


Re: Tapestry 3 and Valid XHTML Forms (generated Script tag)

2007-05-30 Thread Jonathan O'Connor
Andrew,
sorry I can't help you on that. I guess get out and grep for script. Try
putting a breakpoint on the rendering methods, and see what happens.
Ciao,
Jonathan O'Connor
XCOM Dublin


   
 Andrew Ingram 
 [EMAIL PROTECTED] 
 tanemail.com  To 
   Tapestry users  
 30.05.2007 13:58  users@tapestry.apache.org 
cc 
   
 Please respond to Subject 
 Tapestry users  Re: Tapestry 3 and Valid XHTML  
 [EMAIL PROTECTED] Forms (generated Script tag)
pache.org 
   
   
   
   
   




Thanks Jonathan,

I'm down to just one tapestry-generated validation error now.

I'm still getting the language attribute on script tags (example below),
i've looked through the tapestry source and the scripting stuff seems a
bit complicated, even if I tell the component to not use client side
scripting it still generates a small amount of script (used for focusing
the text input).

I'm interested in knowing two things:
1) Where in tapestry is the script tag written and how can I overwrite
it to not use the language attribute?
2) Can I make a validfield generate no javascript whatsoever?

Example output:

script language=JavaScript type=text/javascript
src=/app?service=assetamp;sp=S%2Forg%2Fapache%2Ftapestry%2Fvalid%2FValidator.jsamp;sp=S3dfc7ba91240b3bbd49fbb3efe31/script

script language=JavaScript type=text/javascript!--


function
validate_SearchField()
{
  var field = document.Form0.SearchField;

  if
(field.value.length == 0)
 return validator_invalid_field(field, You
must enter a value for the search to work...);


  if (field.value.length 
1)
 return validator_invalid_field(field, You must enter at least 1
characters for the search to work...);

  return true;
}


window.onload =
function ()
{
document.Form0.SearchField.focus();
document.Form0.SearchField.select();
document.Form0.onsubmit =
validate_SearchField;
}


Regards,
Andrew Ingram



Jonathan O'Connor wrote:


Andrew,
 you will have to roll your own components. The ImageSubmit
component 
 should be fairly easy. Just copy the source for the ImageSubmit
 component, and then alter the code to avoid outputing a border 

attribute. You can probably also extend from ImageSubmit, and change 
 the
rendering.

 You should be able to do the same with the Form class too.


Sorry I can't be more explicit, but its over a year since I did any 

Tapestry work (all Tap3).
 Good luck,
 Jonathan O'Connor
 XCOM Dublin

__
This
email has been scanned by the MessageLabs Email Security System.
For more
information please visit http://www.messagelabs.com/email
__
-
To
unsubscribe, e-mail: [EMAIL PROTECTED]
For additional
commands, e-mail: [EMAIL PROTECTED]




*** XCOM AG Legal Disclaimer ***

Diese E-Mail einschliesslich ihrer Anhaenge ist vertraulich und ist allein
für den Gebrauch durch den vorgesehenen Empfaenger bestimmt. Dritten ist
das Lesen, Verteilen oder Weiterleiten dieser E-Mail untersagt. Wir bitten,
eine fehlgeleitete E-Mail unverzueglich vollstaendig zu loeschen und uns
eine Nachricht zukommen zu lassen.

This email may contain material that is confidential and for the sole use
of the intended recipient. Any review, distribution by others or forwarding
without express permission is strictly prohibited. If you are not the
intended recipient, please contact the sender and delete all copies.

Hauptsitz: Bahnstrasse 37, D-47877 Willich, USt-IdNr.: DE 812 885 664
Kommunikation: Telefon +49 2154 9209-70, Telefax +49 2154 9209-900,
www.xcom.de
Handelsregister: Amtsgericht Krefeld, HRB 10340
Vorstand: Matthias Albrecht, Renate Becker-Grope, Marco Marty, Dr. Rainer
Fuchs
Vorsitzender des Aufsichtsrates: Stephan Steuer

Re: HTML tags....such as Publisher or Front page editor.....

2007-05-30 Thread erwin_br

cirile now i try this:

html xmlns:t=http://tapestry.apache.org/schema/tapestry_5_0_0.xsd;
head
titlemusiclib Start Page/title
/head
FRAMESET COLS=30%, 70%/
FRAME SRC=coluna1.html/
FRAMESET ROWS=20%, 80%/
FRAME SRC=linha1.html/
   FRAME SRC=linha2.html/
body
/body
/html 

the tapestry don´t complain but the web browser don´t show nothing, i
created the coluna1.html and linha1.html and linha2.html with the same
source:

html xmlns:t=http://tapestry.apache.org/schema/tapestry_5_0_0.xsd;
head
titlemusiclib Start Page/title
/head
body BACKGROUND=paper.gif BGCOLOR=#FF TEXT=#00
LINK=#FF VLINK=#FF66FF ALINK=#FF
table t:type=grid rowsPerPage=10 pagerPosition=both
source=tracks
t:parameter name=ratingCell
 
/t:parameter
/table
/body
/html

the browse must show the grid at 3 frames but nothing happened.

whats wrong?
-- 
View this message in context: 
http://www.nabble.com/HTML-tagssuch-as-Publisher-or-Front-page-editor.-tf3840106.html#a10874816
Sent from the Tapestry - User mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: Tables, Forms and Ajax

2007-05-30 Thread Paulo Ramos

My original code:

---
Html :
form jwcid=form
   table jwcid=Tabela 
   td class=lineWithBorderNoWrap nowrap=nowrap 
jwcid=accaoColumnValue

  a href= jwcid=MoreInfoLinkMore Info/a
  div jwcid=MoreInfoAjax
  /div
   /td
   /table
/form

---
Page :

   component id=Tabela type=Contrib:Table
   binding name=source value=list/
   binding name=columns value=literal: id:Id:id, 
nome:Nome:nome, !accao:Accao:accao/

   binding name=row value=ognl:currentLinha/
   binding name=keyExpression value=literal:id/
   /component

   component id=form type=Form /

   component id=accaoColumnValue type=Block /
   component id=MoreInfoLink type=DirectLink 
   binding name=listener value=listener:onMostrar /
   binding name=parameters value=currentLinha.id /
   binding name=updateComponents 
value='MoreInfoAjax'+components.Tabela.tableRow.id/

   binding name=async value=ognl:true /
   /component
  
   component id=MoreInfoAjax type=Any 
   binding name=id 
value='MoreInfoAjax'+components.Tabela.tableRow.id /

   /component
---


When i click More Info from line 2 it render like that:

td id=informal_14 class=accaoColumnValue
   
a id=MoreInfoLink_1 href=/eLoja/tables/CheckboxTestPage3,MoreInfoLink.sdirect?sp=2updateParts=MoreInfoAjax2More 
Info/a

   div id=MoreInfoAjax2
   div id=MoreInfoAjax3/
   /div
/td

Paulo Ramos


smime.p7s
Description: S/MIME Cryptographic Signature


Re: T4.1.1 - How to inject (dynamic) page into component?

2007-05-30 Thread Steve Shucker
I think you're going down the wrong path with page injection.  Try using 
@Parameter to declare/inject a parameter to pass the page.  You can 
either make your parameter a String and use cycle.getPage(pageName) like 
Andreas suggested or make it an IPage or ILoginPage to pass the page 
directly.  If you're just passing a String, you may need to @Inject some 
other bit of infrastructure to resolve it into a page.


-Steve

Jan Vissers wrote:
Ok - but one way or another I want to 'parameterize' my component with 
the
actual page, implementing the ILoginpage interface. So I'm guessing I 
still need

some kind of @Parameter annotation, right?

-J.

Andreas Andreou wrote:

Well, instead of injecting the page,
you can do a cycle.getPage(pageName)


On 5/30/07, Jan Vissers [EMAIL PROTECTED] wrote:


anyone?

 I have a component that 'should' operate on a page it gets injected.

 Currently I have:

 
 import com.cumquatit.refapp.view.tapestry.pages.Loginpage;
 

 public abstract class LoginLogoff extends BaseComponent {
 ...
 @InjectPage(pages/login/Loginpage)
 public abstract Loginpage getLoginpage();
 ...
 }


 This however ties my component to a specific class: Loginpage. I'd
rather
 have something like this:


 public abstract class LoginLogoff extends BaseComponent {
 ...
 // @InjectPage() or @Parameter()
 public abstract ILoginpage getLoginpage();
 ...
 }

 Where the getLoginPage now references an interface ILoginpage, for 
which

a
 concrete implementation is injected via the appropriate annotation.

 Does this make sense, and is this possible?
 If so - how?

 Thanks,
 -J.


 -
 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]









-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



[ANN] Any Tapestry developers around Glasgow UK?

2007-05-30 Thread Kolesnikov, Alexander GNI
Sorry to bother, I will be brief.

The location is Greenock, Scotland, the company is CIGNA International
(current website, still an ASP one, cigna.co.uk). The project is
expanding and we are looking for another Tapestry developer, plus to
myself, to work on the front end.

Cheers,

Alexander

--
CONFIDENTIALITY NOTICE: If you have received this email in error, please 
immediately notify the sender by e-mail at the address shown.  This email 
transmission may contain confidential information.  This information is 
intended only for the use of the individual(s) or entity to whom it is intended 
even if addressed incorrectly.  Please delete it from your files if you are not 
the intended recipient.  Thank you for your compliance.  Copyright 2007 CIGNA
==


Re: URGENT: T4.1.1 on Oracle OC4J 9.0.4, 10.1.2.xxx - Missing classpath resource '/dojo' issue

2007-05-30 Thread Jan Vissers

Well - okay then...
let me rephrase my question - is there any known record of people using 
T4.1.1 on OC4J 9.0.4 or OC4J 10.1.2.xxx


Thx,
-J.

Jesse Kuhnert wrote:
Yep.  Sounds like oracle is messing with your classloader.   I love 
oracle

java software.  I love oracle java software.

On 5/30/07, Jan Vissers [EMAIL PROTECTED] wrote:


Digging deeper, and deeper...

In DefaultClassResolver this method:

public URL getResource(String name)
{
String stripped = removeLeadingSlash(name);

URL result = _loader.getResource(stripped);

return result;
}

returns null for 'dojo/' ...
smells like a class loading issue, doesn't it

any ideas?
-J.

Jan Vissers wrote:
 Checking the (Tapestry) code:

 public IAsset createAbsoluteAsset(String path, Locale locale, Location
 location)
{
Resource base = new ClasspathResource(_classResolver, path);
Resource localized = _localizer.findLocalization(base, locale);

if (localized == null)
throw new
 ApplicationRuntimeException(AssetMessages.missingClasspathResource
(path),
location, null);

return createAsset(localized, location);
}

 _localizer.findLocalization(base, locale);
 Returns null for '/dojo' ... why would this happen?

 Thanks,
 -J.

 Jan Vissers wrote:
 Hi,

 I'm starting a new project for a customer of ours and want to use
 Tapestry 4.1.1 on Oracle's J2EE container - OC4J.
 Having tested various aspects of this T version on 10.1.3 - I'm
 pretty keen on using this version, however there are issues...

 Firstly I ran into a known issue with Hivemind's URLResource class on
 OC4J 9.0.4/10.1.2.xxx.
 I used a proposed hack to fix this issue. But now when I drop a Shell
 component on a form, I get this error:

 Caused by: org.apache.hivemind.ApplicationRuntimeException: Missing
 classpath resource '/dojo/'.
 [classpath:/org/apache/tapestry/html/Shell.jwc, line 179, column 61]
 at
 org.apache.tapestry.asset.ClasspathAssetFactory.createAbsoluteAsset(
ClasspathAssetFactory.java:61)

 at

$AssetFactory_112dd0124f3.createAbsoluteAsset($AssetFactory_112dd0124f3.java) 



 at
 org.apache.tapestry.asset.AssetSourceImpl.findAsset(
AssetSourceImpl.java:84)

 at
$AssetSource_112dd0124a7.findAsset($AssetSource_112dd0124a7.java)
 at
 org.apache.tapestry.pageload.PageLoader.convertAsset(PageLoader.java
:695)

 at
 
org.apache.tapestry.pageload.PageLoader.addAssets(PageLoader.java:670)

 at
 org.apache.tapestry.pageload.PageLoader.constructComponent(
PageLoader.java:415)

 at
 org.apache.tapestry.pageload.PageLoader.createImplicitComponent(
PageLoader.java:478)

 at

$IPageLoader_112dd0124a3.createImplicitComponent($IPageLoader_112dd0124a3.java) 



 at

$IPageLoader_112dd0124a4.createImplicitComponent($IPageLoader_112dd0124a4.java) 



 at

org.apache.tapestry.services.impl.ComponentTemplateLoaderLogic.createImplicitComponent 


(ComponentTemplateLoaderLogic.java:218)

 at
 
org.apache.tapestry.services.impl.ComponentTemplateLoaderLogic.process(

ComponentTemplateLoaderLogic.java:172)

 at
 
org.apache.tapestry.services.impl.ComponentTemplateLoaderLogic.process(

ComponentTemplateLoaderLogic.java:111)

 at

org.apache.tapestry.services.impl.ComponentTemplateLoaderLogic.loadTemplate 


(ComponentTemplateLoaderLogic.java:88)

 at

org.apache.tapestry.services.impl.ComponentTemplateLoaderImpl.loadTemplate 


(ComponentTemplateLoaderImpl.java:61)

 at

$ComponentTemplateLoader_112dd0124ad.loadTemplate($ComponentTemplateLoader_112dd0124ad.java) 



 at
 org.apache.tapestry.pageload.PageLoader.loadTemplateForComponent(
PageLoader.java:637)

 at
 org.apache.tapestry.BaseComponent.readTemplate(BaseComponent.java:77)
 at
 org.apache.tapestry.BaseComponent.finishLoad(BaseComponent.java:107)
 at $Exception_5.finishLoad($Exception_5.java)
 at
 org.apache.tapestry.pageload.PageLoader.constructComponent(
PageLoader.java:425)

 at
 org.apache.tapestry.pageload.PageLoader.loadPage(PageLoader.java:600)
 at 
$IPageLoader_112dd0124a3.loadPage($IPageLoader_112dd0124a3.java)
 at 
$IPageLoader_112dd0124a4.loadPage($IPageLoader_112dd0124a4.java)

 at
 org.apache.tapestry.pageload.PageSource.getPage(PageSource.java:119)
 at 
$IPageSource_112dd012406.getPage($IPageSource_112dd012406.java)

 at
 
org.apache.tapestry.engine.RequestCycle.loadPage(RequestCycle.java:248)

 at
 
org.apache.tapestry.engine.RequestCycle.getPage(RequestCycle.java:235)

 at
 org.apache.tapestry.error.ExceptionPresenterImpl.presentException(
ExceptionPresenterImpl.java:42)

 ... 30 more


 Can somebody enlighten me what's wrong here and whether or not this
 is a known issue?
 I sure as * hope I don't have to hack my way around this
 (probably Oracle related) issue also...

 Thanks,
 -J.


 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For 

Re: ComponentClassResolverImpl

2007-05-30 Thread Howard Lewis Ship

url() references in a stylesheet a relative to the stylesheet.
url(images/bg.gif) will generate a proper URL to a real resource, and
Tapestry won't attempt to interpret it as an action request URL.

On 5/30/07, petros [EMAIL PROTECTED] wrote:



I have the following error in my log file

java.lang.IllegalArgumentException: Unable to resolve page
'styles/images/bg' to a component class name.  Available page names:
Login,
Start,  users/UserDetails
at

org.apache.tapestry.internal.services.ComponentClassResolverImpl.resolvePageNameToClassName
(ComponentClassResolverImpl.java:257)

which is caused by the line (in style.css)
background: #f4f4f4 url(styles/images/bg.gif) top center repeat-y;

The directory structure is
/styles/images/bg.gif
/styles/style.css

How can I solve this problem ?

Petros




--
View this message in context:
http://www.nabble.com/ComponentClassResolverImpl-tf3838585.html#a10868505
Sent from the Tapestry - User mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]





--
Howard M. Lewis Ship
TWD Consulting, Inc.
Independent J2EE / Open-Source Java Consultant
Creator and PMC Chair, Apache Tapestry
Creator, Apache HiveMind

Professional Tapestry training, mentoring, support
and project work.  http://howardlewisship.com


Re: T5 I need to be able to dynamically render components

2007-05-30 Thread Howard Lewis Ship

Tapestry pages are static in structure: you don't just create components on
the fly.  This is necessary for Tapestry's view on scalability and
clustering.

What you can do is define th components you want and select which one
renders at any give time.  This is how the Grid and BeanEditForm components
work, for example.

On 5/29/07, Jonathan Glanz [EMAIL PROTECTED] wrote:


All, below is a sample of what I'd like to be able to do, but I can't seem
to figure out a way to make it work



t:loop source=widgets value=widget

div t:type=prop:viewElementType/

/t:loop



Is there a way to do this or a binding that would do this?  Basically I
need
a way to dynamically instantiate components at runtime.



-thx, Jon





--
Howard M. Lewis Ship
TWD Consulting, Inc.
Independent J2EE / Open-Source Java Consultant
Creator and PMC Chair, Apache Tapestry
Creator, Apache HiveMind

Professional Tapestry training, mentoring, support
and project work.  http://howardlewisship.com


Re: Anyone can answer this?

2007-05-30 Thread Howard Lewis Ship

I'm not sure, Kent sort of dropped out of the project, but is still a
committer.

Kent had a very different view of what Tapestry 5 should be, and it really
was more like Wicket.  It was Tapestry without the concept of parameters and
bindings ... really a lot more like Swing.  A container, such as a page,
would have to write code to set any and all properties of each embedded
component before it rendered. This was counter to my personal view of
Tapestry, one in which Tapestry weaves together the functioning
application from a minimum of configuration.  Anyway, this code-heavy but
type-safe approach is closer to the Wicket view.

Caution: We've been having problems with some immature outliers in the
Tapestry community coming in and starting flame wars.

On 5/30/07, Joseph Kobe [EMAIL PROTECTED] wrote:


Hi,I'm new to Tapestry and was making a search on google to find out some
more about what people are saying about it but came across this post by Kent
Tong-
http://www.nabble.com/Problem-loading-dynamic-image-using-ajax-tf3805423.htmlHasthis
 Tapestry book author, high profile user and commiter deflected to
Wicket?This begs the question what attracted him to Wicket? I've heard
recently many, many positivethings about Wicket and I'm tempted to go have a
look at it instead.Does anyone care to give some
comparisons?Regards,Joseph
_
http://www.live.com/?mkt=nl-nl
Live.nl





--
Howard M. Lewis Ship
TWD Consulting, Inc.
Independent J2EE / Open-Source Java Consultant
Creator and PMC Chair, Apache Tapestry
Creator, Apache HiveMind

Professional Tapestry training, mentoring, support
and project work.  http://howardlewisship.com


Re: T5: when is @Persist necessary and when not...

2007-05-30 Thread Howard Lewis Ship

@Persist isn't about database persistence; it is about a value persisting
from one request to the next, or beyond.

Tapestry uses a redirect-after-post for actions, including form submits.
Thus if the data is stored persistently, usually in the HttpSession, it is
gone on the second request, the one that actually renders a response.

If you used the debugger, you'd see that your _person field would also be
null in the second request, the render request. You just aren't using it.

On 5/30/07, Martin Dietze [EMAIL PROTECTED] wrote:


Hi,

I have a page class which keeps form data like this:

| // class MyForm
| private Person _person;
| private String _homepage;

The class Person consists of several fields:

| // class Person
| private String _firstName
| private String _lastName

For all these I have getters and setters defined.

In my page class I have a constructor like this:

| public CreatePartner() {
|   _contact = new Person();
| }

When I submit data in my form all the above gets written
to the database as expected. However the textinput referring
to the _homepage member variable is always empty.

Now if I annotate the _homepage member variable using
@Persist(flash), I get the data displayed as expected.
This seems to indicate that simple objects are somehow
treated differently from the way compound objects are
treated?

Strictly speaking I would not expect to need any persistence
annotation here at all since I am only handling submitted
data, or do I misunderstand anything here?

Cheers,

Martin

P.S.: These is the relevant entries in my form:

| input type=text name=firstname id=firstname tabindex=20
| t:type=textfield
| t:id=firstname
| t:value=contact.firstname
| t:validate=required,minlength=3
| /

[...]

| input type=text name=lastname id=lastname tabindex=20
| t:type=textfield
| t:id=lastname
| t:value=contact.lastname
| t:validate=required,minlength=3
| /

[...]

| input type=text name=homepage id=homepage tabindex=40
| t:type=textfield
| t:id=homepage
| t:value=homepage
| t:validate=required,minlength=3
| /


Martin

--
-- Martin Dietze --- / -- freiheit.com--
-- [EMAIL PROTECTED] -- / --
[EMAIL PROTECTED] -
- / http://herbert.the-little-red-haired-girl.org /
-
=+=
Last yeer I kudn't spel Engineer.  Now I are won.

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]





--
Howard M. Lewis Ship
TWD Consulting, Inc.
Independent J2EE / Open-Source Java Consultant
Creator and PMC Chair, Apache Tapestry
Creator, Apache HiveMind

Professional Tapestry training, mentoring, support
and project work.  http://howardlewisship.com


Re: ComponentClassResolverImpl

2007-05-30 Thread Daniel Jue

hint:
assuming your css is in webapp/css,

url(images/bg.gif)  would point to webapp/css/images/bg.gif
url(/images/bg.gif) would also point to webapp/css/images/bg.gif
url(../images/bg.gif) would point to webapp/images/bg.gif

I was just solving this issue with my code as well.
BTW- I noticed that I can't save an edited css file in eclipse, if
jetty is running and has served the page (ie6 or firefox)

Could not write file:
C:\Projects\wtpworkspace\IEIS2\src\main\webapp\css\test.css.
So I have to stop and restart jetty6. =(




On 5/30/07, Howard Lewis Ship [EMAIL PROTECTED] wrote:

url() references in a stylesheet a relative to the stylesheet.
url(images/bg.gif) will generate a proper URL to a real resource, and
Tapestry won't attempt to interpret it as an action request URL.

On 5/30/07, petros [EMAIL PROTECTED] wrote:


 I have the following error in my log file

 java.lang.IllegalArgumentException: Unable to resolve page
 'styles/images/bg' to a component class name.  Available page names:
 Login,
 Start,  users/UserDetails
 at

 
org.apache.tapestry.internal.services.ComponentClassResolverImpl.resolvePageNameToClassName
 (ComponentClassResolverImpl.java:257)

 which is caused by the line (in style.css)
 background: #f4f4f4 url(styles/images/bg.gif) top center repeat-y;

 The directory structure is
 /styles/images/bg.gif
 /styles/style.css

 How can I solve this problem ?

 Petros




 --
 View this message in context:
 http://www.nabble.com/ComponentClassResolverImpl-tf3838585.html#a10868505
 Sent from the Tapestry - User mailing list archive at Nabble.com.


 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]




--
Howard M. Lewis Ship
TWD Consulting, Inc.
Independent J2EE / Open-Source Java Consultant
Creator and PMC Chair, Apache Tapestry
Creator, Apache HiveMind

Professional Tapestry training, mentoring, support
and project work.  http://howardlewisship.com



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



RE: T5 I need to be able to dynamically render components

2007-05-30 Thread Jonathan Glanz
Howard you read my mind, ideally dynamic components would be great, but I
ended up just defining several blocks and then delegating which one to show,
small price to pay for the flat out RAD of T5.

-Jon

-Original Message-
From: Howard Lewis Ship [mailto:[EMAIL PROTECTED] 
Sent: Wednesday, May 30, 2007 7:51 AM
To: Tapestry users
Subject: Re: T5 I need to be able to dynamically render components

Tapestry pages are static in structure: you don't just create components on
the fly.  This is necessary for Tapestry's view on scalability and
clustering.

What you can do is define th components you want and select which one
renders at any give time.  This is how the Grid and BeanEditForm components
work, for example.

On 5/29/07, Jonathan Glanz [EMAIL PROTECTED] wrote:

 All, below is a sample of what I'd like to be able to do, but I can't seem
 to figure out a way to make it work



 t:loop source=widgets value=widget

 div t:type=prop:viewElementType/

 /t:loop



 Is there a way to do this or a binding that would do this?  Basically I
 need
 a way to dynamically instantiate components at runtime.



 -thx, Jon




-- 
Howard M. Lewis Ship
TWD Consulting, Inc.
Independent J2EE / Open-Source Java Consultant
Creator and PMC Chair, Apache Tapestry
Creator, Apache HiveMind

Professional Tapestry training, mentoring, support
and project work.  http://howardlewisship.com


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: URGENT: T4.1.1 on Oracle OC4J 9.0.4, 10.1.2.xxx - Missing classpath resource '/dojo' issue

2007-05-30 Thread Jan Vissers
The ClassLoader held by org.apache.hivemind.impl.DefaultClassResolver 
has this:


[ClassLoader: 
[[D:\ora\ocj10_1_2_0_2\j2ee\home\applications\eva\eva-web-1.0.0\WEB-INF\classes], 
[D:\ora\ocj10_1_2_0_2\j2ee\home\applications\eva\eva-web-1.0.0\WEB-INF\lib\backport-util-concurrent-4.1.1.jar 
archive], 
[D:\ora\ocj10_1_2_0_2\j2ee\home\applications\eva\eva-web-1.0.0\WEB-INF\lib\commons-codec-1.3.jar 
archive], 
[D:\ora\ocj10_1_2_0_2\j2ee\home\applications\eva\eva-web-1.0.0\WEB-INF\lib\commons-io-1.3.1.jar 
archive], 
[D:\ora\ocj10_1_2_0_2\j2ee\home\applications\eva\eva-web-1.0.0\WEB-INF\lib\commons-lang-2.2.jar 
archive], 
[D:\ora\ocj10_1_2_0_2\j2ee\home\applications\eva\eva-web-1.0.0\WEB-INF\lib\commons-logging-1.0.3.jar 
archive], 
[D:\ora\ocj10_1_2_0_2\j2ee\home\applications\eva\eva-web-1.0.0\WEB-INF\lib\hivemind-lib-1.1.1.jar 
archive], 
[D:\ora\ocj10_1_2_0_2\j2ee\home\applications\eva\eva-web-1.0.0\WEB-INF\lib\hivemind-oc4j-1.1.1.jar 
archive], 
[D:\ora\ocj10_1_2_0_2\j2ee\home\applications\eva\eva-web-1.0.0\WEB-INF\lib\jakarta-oro-2.0.8.jar 
archive], 
[D:\ora\ocj10_1_2_0_2\j2ee\home\applications\eva\eva-web-1.0.0\WEB-INF\lib\javassist-3.0.jar 
archive], 
[D:\ora\ocj10_1_2_0_2\j2ee\home\applications\eva\eva-web-1.0.0\WEB-INF\lib\ognl-2.6.9.jar 
archive], 
[D:\ora\ocj10_1_2_0_2\j2ee\home\applications\eva\eva-web-1.0.0\WEB-INF\lib\tapestry-framework-4.1.1.jar 
archive]]]


'/dojo/' is in tapestry-framework-4.1.1.jar - maybe I am missing some 
basic understanding here, but

why the hell is '/dojo' not found?

-J.


Jan Vissers wrote:

Well - okay then...
let me rephrase my question - is there any known record of people 
using T4.1.1 on OC4J 9.0.4 or OC4J 10.1.2.xxx


Thx,
-J.

Jesse Kuhnert wrote:
Yep.  Sounds like oracle is messing with your classloader.   I love 
oracle

java software.  I love oracle java software.

On 5/30/07, Jan Vissers [EMAIL PROTECTED] wrote:


Digging deeper, and deeper...

In DefaultClassResolver this method:

public URL getResource(String name)
{
String stripped = removeLeadingSlash(name);

URL result = _loader.getResource(stripped);

return result;
}

returns null for 'dojo/' ...
smells like a class loading issue, doesn't it

any ideas?
-J.

Jan Vissers wrote:
 Checking the (Tapestry) code:

 public IAsset createAbsoluteAsset(String path, Locale locale, 
Location

 location)
{
Resource base = new ClasspathResource(_classResolver, path);
Resource localized = _localizer.findLocalization(base, 
locale);


if (localized == null)
throw new
 ApplicationRuntimeException(AssetMessages.missingClasspathResource
(path),
location, null);

return createAsset(localized, location);
}

 _localizer.findLocalization(base, locale);
 Returns null for '/dojo' ... why would this happen?

 Thanks,
 -J.

 Jan Vissers wrote:
 Hi,

 I'm starting a new project for a customer of ours and want to use
 Tapestry 4.1.1 on Oracle's J2EE container - OC4J.
 Having tested various aspects of this T version on 10.1.3 - I'm
 pretty keen on using this version, however there are issues...

 Firstly I ran into a known issue with Hivemind's URLResource 
class on

 OC4J 9.0.4/10.1.2.xxx.
 I used a proposed hack to fix this issue. But now when I drop a 
Shell

 component on a form, I get this error:

 Caused by: org.apache.hivemind.ApplicationRuntimeException: Missing
 classpath resource '/dojo/'.
 [classpath:/org/apache/tapestry/html/Shell.jwc, line 179, column 61]
 at
 org.apache.tapestry.asset.ClasspathAssetFactory.createAbsoluteAsset(
ClasspathAssetFactory.java:61)

 at

$AssetFactory_112dd0124f3.createAbsoluteAsset($AssetFactory_112dd0124f3.java) 



 at
 org.apache.tapestry.asset.AssetSourceImpl.findAsset(
AssetSourceImpl.java:84)

 at
$AssetSource_112dd0124a7.findAsset($AssetSource_112dd0124a7.java)
 at
 org.apache.tapestry.pageload.PageLoader.convertAsset(PageLoader.java
:695)

 at
 
org.apache.tapestry.pageload.PageLoader.addAssets(PageLoader.java:670)

 at
 org.apache.tapestry.pageload.PageLoader.constructComponent(
PageLoader.java:415)

 at
 org.apache.tapestry.pageload.PageLoader.createImplicitComponent(
PageLoader.java:478)

 at

$IPageLoader_112dd0124a3.createImplicitComponent($IPageLoader_112dd0124a3.java) 



 at

$IPageLoader_112dd0124a4.createImplicitComponent($IPageLoader_112dd0124a4.java) 



 at

org.apache.tapestry.services.impl.ComponentTemplateLoaderLogic.createImplicitComponent 


(ComponentTemplateLoaderLogic.java:218)

 at
 
org.apache.tapestry.services.impl.ComponentTemplateLoaderLogic.process(

ComponentTemplateLoaderLogic.java:172)

 at
 
org.apache.tapestry.services.impl.ComponentTemplateLoaderLogic.process(

ComponentTemplateLoaderLogic.java:111)

 at

org.apache.tapestry.services.impl.ComponentTemplateLoaderLogic.loadTemplate 


(ComponentTemplateLoaderLogic.java:88)

 at


Re: ComponentClassResolverImpl

2007-05-30 Thread Jesse Kuhnert

That's a jetty configuration setting.  I don't remember the exact place /
config option but you can find it in the jetty confluence site somewhere.
Something to do with windows file locking.

On 5/30/07, Daniel Jue [EMAIL PROTECTED] wrote:


hint:
assuming your css is in webapp/css,

url(images/bg.gif)  would point to webapp/css/images/bg.gif
url(/images/bg.gif) would also point to webapp/css/images/bg.gif
url(../images/bg.gif) would point to webapp/images/bg.gif

I was just solving this issue with my code as well.
BTW- I noticed that I can't save an edited css file in eclipse, if
jetty is running and has served the page (ie6 or firefox)

Could not write file:
C:\Projects\wtpworkspace\IEIS2\src\main\webapp\css\test.css.
So I have to stop and restart jetty6. =(




On 5/30/07, Howard Lewis Ship [EMAIL PROTECTED] wrote:
 url() references in a stylesheet a relative to the stylesheet.
 url(images/bg.gif) will generate a proper URL to a real resource, and
 Tapestry won't attempt to interpret it as an action request URL.

 On 5/30/07, petros [EMAIL PROTECTED] wrote:
 
 
  I have the following error in my log file
 
  java.lang.IllegalArgumentException: Unable to resolve page
  'styles/images/bg' to a component class name.  Available page names:
  Login,
  Start,  users/UserDetails
  at
 
 
org.apache.tapestry.internal.services.ComponentClassResolverImpl.resolvePageNameToClassName
  (ComponentClassResolverImpl.java:257)
 
  which is caused by the line (in style.css)
  background: #f4f4f4 url(styles/images/bg.gif) top center repeat-y;
 
  The directory structure is
  /styles/images/bg.gif
  /styles/style.css
 
  How can I solve this problem ?
 
  Petros
 
 
 
 
  --
  View this message in context:
 
http://www.nabble.com/ComponentClassResolverImpl-tf3838585.html#a10868505
  Sent from the Tapestry - User mailing list archive at Nabble.com.
 
 
  -
  To unsubscribe, e-mail: [EMAIL PROTECTED]
  For additional commands, e-mail: [EMAIL PROTECTED]
 
 


 --
 Howard M. Lewis Ship
 TWD Consulting, Inc.
 Independent J2EE / Open-Source Java Consultant
 Creator and PMC Chair, Apache Tapestry
 Creator, Apache HiveMind

 Professional Tapestry training, mentoring, support
 and project work.  http://howardlewisship.com


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]





--
Jesse Kuhnert
Tapestry/Dojo team member/developer

Open source based consulting work centered around
dojo/tapestry/tacos/hivemind. http://blog.opencomponentry.com


Re: URGENT: T4.1.1 on Oracle OC4J 9.0.4, 10.1.2.xxx - Missing classpath resource '/dojo' issue

2007-05-30 Thread Jesse Kuhnert

I'm not sure.  Only the wonderful oracle java developers know for sure I'm
guessing.

You can try messing with that or searching oracle related things for
configuring / changing the classloader settings.  Tapestry will ultimately
defer class (and class resource) resolution up to whatever class loader it
is running in - so it clearly has to be something oracle is f$#-ing up -
again.

On 5/30/07, Jan Vissers [EMAIL PROTECTED] wrote:


The ClassLoader held by org.apache.hivemind.impl.DefaultClassResolver
has this:

[ClassLoader:
[[D:\ora\ocj10_1_2_0_2\j2ee\home\applications\eva\eva-
web-1.0.0\WEB-INF\classes],
[D:\ora\ocj10_1_2_0_2\j2ee\home\applications\eva\eva-
web-1.0.0\WEB-INF\lib\backport-util-concurrent-4.1.1.jar
archive],
[D:\ora\ocj10_1_2_0_2\j2ee\home\applications\eva\eva-
web-1.0.0\WEB-INF\lib\commons-codec-1.3.jar
archive],
[D:\ora\ocj10_1_2_0_2\j2ee\home\applications\eva\eva-
web-1.0.0\WEB-INF\lib\commons-io-1.3.1.jar
archive],
[D:\ora\ocj10_1_2_0_2\j2ee\home\applications\eva\eva-
web-1.0.0\WEB-INF\lib\commons-lang-2.2.jar
archive],
[D:\ora\ocj10_1_2_0_2\j2ee\home\applications\eva\eva-
web-1.0.0\WEB-INF\lib\commons-logging-1.0.3.jar
archive],
[D:\ora\ocj10_1_2_0_2\j2ee\home\applications\eva\eva-
web-1.0.0\WEB-INF\lib\hivemind-lib-1.1.1.jar
archive],
[D:\ora\ocj10_1_2_0_2\j2ee\home\applications\eva\eva-
web-1.0.0\WEB-INF\lib\hivemind-oc4j-1.1.1.jar
archive],
[D:\ora\ocj10_1_2_0_2\j2ee\home\applications\eva\eva-
web-1.0.0\WEB-INF\lib\jakarta-oro-2.0.8.jar
archive],
[D:\ora\ocj10_1_2_0_2\j2ee\home\applications\eva\eva-
web-1.0.0\WEB-INF\lib\javassist-3.0.jar
archive],
[D:\ora\ocj10_1_2_0_2\j2ee\home\applications\eva\eva-
web-1.0.0\WEB-INF\lib\ognl-2.6.9.jar
archive],
[D:\ora\ocj10_1_2_0_2\j2ee\home\applications\eva\eva-
web-1.0.0\WEB-INF\lib\tapestry-framework-4.1.1.jar
archive]]]

'/dojo/' is in tapestry-framework-4.1.1.jar - maybe I am missing some
basic understanding here, but
why the hell is '/dojo' not found?

-J.


Jan Vissers wrote:
 Well - okay then...
 let me rephrase my question - is there any known record of people
 using T4.1.1 on OC4J 9.0.4 or OC4J 10.1.2.xxx

 Thx,
 -J.

 Jesse Kuhnert wrote:
 Yep.  Sounds like oracle is messing with your classloader.   I love
 oracle
 java software.  I love oracle java software.

 On 5/30/07, Jan Vissers [EMAIL PROTECTED] wrote:

 Digging deeper, and deeper...

 In DefaultClassResolver this method:

 public URL getResource(String name)
 {
 String stripped = removeLeadingSlash(name);

 URL result = _loader.getResource(stripped);

 return result;
 }

 returns null for 'dojo/' ...
 smells like a class loading issue, doesn't it

 any ideas?
 -J.

 Jan Vissers wrote:
  Checking the (Tapestry) code:
 
  public IAsset createAbsoluteAsset(String path, Locale locale,
 Location
  location)
 {
 Resource base = new ClasspathResource(_classResolver, path);
 Resource localized = _localizer.findLocalization(base,
 locale);
 
 if (localized == null)
 throw new
  ApplicationRuntimeException(AssetMessages.missingClasspathResource
 (path),
 location, null);
 
 return createAsset(localized, location);
 }
 
  _localizer.findLocalization(base, locale);
  Returns null for '/dojo' ... why would this happen?
 
  Thanks,
  -J.
 
  Jan Vissers wrote:
  Hi,
 
  I'm starting a new project for a customer of ours and want to use
  Tapestry 4.1.1 on Oracle's J2EE container - OC4J.
  Having tested various aspects of this T version on 10.1.3 - I'm
  pretty keen on using this version, however there are issues...
 
  Firstly I ran into a known issue with Hivemind's URLResource
 class on
  OC4J 9.0.4/10.1.2.xxx.
  I used a proposed hack to fix this issue. But now when I drop a
 Shell
  component on a form, I get this error:
 
  Caused by: org.apache.hivemind.ApplicationRuntimeException: Missing
  classpath resource '/dojo/'.
  [classpath:/org/apache/tapestry/html/Shell.jwc, line 179, column
61]
  at
  org.apache.tapestry.asset.ClasspathAssetFactory.createAbsoluteAsset
(
 ClasspathAssetFactory.java:61)
 
  at
 

$AssetFactory_112dd0124f3.createAbsoluteAsset($AssetFactory_112dd0124f3.java)

 
  at
  org.apache.tapestry.asset.AssetSourceImpl.findAsset(
 AssetSourceImpl.java:84)
 
  at
 $AssetSource_112dd0124a7.findAsset($AssetSource_112dd0124a7.java)
  at
  org.apache.tapestry.pageload.PageLoader.convertAsset(
PageLoader.java
 :695)
 
  at
 
 org.apache.tapestry.pageload.PageLoader.addAssets(PageLoader.java:670)
  at
  org.apache.tapestry.pageload.PageLoader.constructComponent(
 PageLoader.java:415)
 
  at
  org.apache.tapestry.pageload.PageLoader.createImplicitComponent(
 PageLoader.java:478)
 
  at
 

$IPageLoader_112dd0124a3.createImplicitComponent($IPageLoader_112dd0124a3.java)

 
  at
 

$IPageLoader_112dd0124a4.createImplicitComponent($IPageLoader_112dd0124a4.java)

 
  at
 


Re: T5: when is @Persist necessary and when not...

2007-05-30 Thread Martin Dietze
On Wed, May 30, 2007, Howard Lewis Ship wrote:

 I have a page class which keeps form data like this:
 
 | // class MyForm
 | private Person _person;
 | private String _homepage;
 
 The class Person consists of several fields:
 
 | // class Person
 | private String _firstName
 | private String _lastName
 
 For all these I have getters and setters defined.
 
 In my page class I have a constructor like this:
 
 | public CreatePartner() {
 |   _contact = new Person();
^^^ `person' of course!
 | }

[...]

 Tapestry uses a redirect-after-post for actions, including form submits.
 Thus if the data is stored persistently, usually in the HttpSession, it is
 gone on the second request, the one that actually renders a response.

 If you used the debugger, you'd see that your _person field would also be
 null in the second request, the render request. You just aren't using it.

Interestingly this does not seem to be the case in my
application. Debugging the above class I find that when the
page is rendered after submit the `Person' object still
contains the submitted values.

Additionally `_$person_default' object (as I guess created by 
T5) contains the values of the populated person object.

For the `_homeapage' object which is an ordinary String, the
values are lost unless I put a [EMAIL PROTECTED](flash)' above it
which should be expected according to your post. Now I wonder
why does the Person object seem to behave differently?

Cheers,

Martin

-- 
- / http://herbert.the-little-red-haired-girl.org / -
=+= 
The only intuitive interface is the nipple. After that, it's all
learned.  -- Bruce Ediger 

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: t5: Date input component

2007-05-30 Thread Juan Maya

Here is the DateInput component for t5:
http://juanemaya.blogspot.com/2007/05/tapestry-5-date-input-component.html
I am not sure if that's the best way to do it. I think that building the
date in the year set is not the best way but well, i am learning slowly :)

Thanks a lot for ur help!

On 5/29/07, Juan Maya [EMAIL PROTECTED] wrote:


Thanks Alexander!
I have used your idea and i have component already working! :) I just need
to add a validator and that's it. Hopefully i will have time to finish it
tomorrow so i will post the code to show the t5 way (And it's quiet easy!:)

On 5/29/07, Kolesnikov, Alexander GNI [EMAIL PROTECTED]
wrote:

 Well, here is the code. If you need comments, the whole issue will be
 published soon, hopefully on the next week. That will be #14, and there are
 three other issues to be published before it:

 #11: DatePicker and Shell
 #12: PropertySelection and IPropertySelectionModel
 #13: Autocompleter and InlineEditBox

 Cheers,

 Alexander

 ***

 Template:

 html
 head
 titleDateInput Template/title
 /head
 body jwcid=$content$
 select jwcid=month
 optionJanuary/option
 optionFebruary/option
 /select
 select jwcid=day
 option1/option
 option2/option
 /select,
 select jwcid=year
 option2005/option
 option2006/option
 /select
 /body
 /html

 Specification:

 ?xml version=1.0  encoding=UTF-8?
 !DOCTYPE component-specification PUBLIC
 -//Apache Software Foundation//Tapestry Specification 4.0//EN
  http://jakarta.apache.org/tapestry/dtd/Tapestry_4_0.dtd;

 component-specification
 class=com.devshed.tapestry.celebrities.DateInput

 descriptionComponent for choosing a date/description

 component id=day type=PropertySelection
 binding name=model value=daysModel/
 binding name=value value=day/
 /component
 component id=month type=PropertySelection
 binding name=model value=monthsModel/
 binding name=value value=month/
 /component
 component id=year type=PropertySelection
 binding name=model value=yearsModel/
 binding name=value value=year/
 /component

 /component-specification

 Class:

 public abstract class DateInput extends BaseComponent implements
 PageBeginRenderListener {

 @Parameter(required = true)
 public abstract Date getDate();
 public abstract void setDate(Date d);

 private Calendar c = Calendar.getInstance();

 public void pageBeginRender(PageEvent event) {
 c.setTime(getDate() == null ? new Date() : getDate());
 }

 public IPropertySelectionModel getDaysModel() {
 return new DayModel();
 }

 public IPropertySelectionModel getMonthsModel() {
 return new LocalisedMonthsModel(getPage().getLocale());
 }

 public IPropertySelectionModel getYearsModel() {
 return new YearModel();
 }

 public int getDay() {
 return c.get(Calendar.DATE);
 }

 public void setDay(int day) {
 c.set(Calendar.DATE, day);
 }

 public int getMonth() {
 return c.get(Calendar.MONTH);
 }

 public void setMonth(int month) {
 c.set(Calendar.MONTH, month);
 }

 public int getYear() {
 return c.get(Calendar.YEAR);
 }

 public void setYear(int year) {
 c.set(Calendar.YEAR, year);
 setDate(c.getTime());
 }
 }

 Models:

 public class DayModel implements IPropertySelectionModel {

 public String getLabel(int index) {
 return  + (index + 1);
 }

 public Object getOption(int index) {
 return index + 1;
 }

 public int getOptionCount() {
 return 31;
 }

 public String getValue(int index) {
 return  + index;
 }

 public Object translateValue(String value) {
 return Integer.parseInt(value) + 1;
 }
 }

 public class YearModel implements IPropertySelectionModel {

 private final static int START_YEAR = 1900;
 private final static int END_YEAR =
 new GregorianCalendar().get(Calendar.YEAR);

 public String getLabel(int index) {
 return Integer.toString(index + START_YEAR);
 }

 public Object getOption(int index) {
 return index + START_YEAR;
 }

 public int getOptionCount() {
 return END_YEAR - START_YEAR + 1;
 }

 public String getValue(int index) {
 return  + index;
 }

 public Object translateValue(String value) {
 return Integer.parseInt(value) + START_YEAR;
 }

 }

 public class LocalisedMonthsModel implements IPropertySelectionModel {

 private String[] months;

 public LocalisedMonthsModel(Locale locale) {
 DateFormatSymbols symbols = new DateFormatSymbols(locale);
 months = symbols.getMonths();
 }

 public String 

Re: dojo dialog to populate portion of form and submit

2007-05-30 Thread Miguel Angel Hernández

Hi Paul I've been in a very similar situation(but in tap4 with tacos)
you're in. To solve it I decided to implement my own Dialog component which
can be contained inside a form, and this worked fine for me. I've controlled
the show and hide issue with Javascript and css. So the component its always
rendered. I'll post the code if you are interested.

On 5/30/07, Paul Stanton [EMAIL PROTECTED] wrote:


I've just tried a javascript writeback hack (trying to keep it
tapestry-ish, yet it's a hack for sure)

basically, the dialog's form elements are Any's so they populate
correctly, but don't submit to tapestry. then when the submit button is
clicked they Any's values are sucked into some hidden (TextField with
display:none in css) and the form is submitted.

I figured this would take advantage of the ajax parts that work for me,
and avoid what isn't working. the problem with this is that:
1. I need to make use of a converter to make sure that tapestry can find
the appropriate object on rewind; i can't figure out how to use a
converter on a plain old TextField or Hidden
2. If there are validation issues with the user input, the Any component
needs to receive the validator message etc, not the invisible TextField.

I'd love to be able to change my border component so that the
LinkSubmit's can sit outside of the form (substitute them with something
else) so that pages can define their own forms and where they begin/end,
however that in it's self will be a hack and it means changing ten pages
to include a hack vs changing 1 page to include a hack (if i can hack
through this dialog issue).

Any suggestions welcome. Paul.

Paul Stanton wrote:
 4.1.1

 Firstly, I'm pretty sure what I'm trying to do is not possible, so
 read on with that in mind.

 My border component defines my form. This is necessary because I have
 a tabbed structure where the tabs are LinkSubmit's and need to be
 associated with a Form.

 My page has part of the form content always displayed, normally
 without ajax or anything dynamic. This part is a list of elements with
 checkboxes to enable/disable.

 When clicking on an element in the list, a dojo Dialog is displayed
 containing a previously existant yet hidden portion of the form to
 edit the attributes of the element along with a LinkSubmit to submit
 the whole form (border form) when the user is done.

 Note that I must continue the existing border's form as the dialog
 code needs to sit within the border, otherwise it would fall outside
 of the html element.

 I can't for the life of me get this to work. I think because the
 Dialog is re-rendered (updateComponent) the dialogs portion of the
 form is essentially detached from the border forms request cycle. No
 matter what I enter in the dialog, nothing comes back to the listener
 when the form is submitted.

 Is what I'm trying to do possible, or do I need to rip apart my border
 component so that I can embed a separate form in the dialog?

 Thanks, Paul.


 -
 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]




T5: Works in Jetty but not in Tomcat

2007-05-30 Thread Joel Wiegman
My application is working fine in Jetty but not in Tomcat.

I've already followed the deployment instructions found here (
http://tapestry.apache.org/tapestry5/tomcat.html ).  I confirmed that my
classes are being jarred up by Maven and put into the WEB-INF/lib
directory.

Using JDK 1.5.0_11, and Tomcat 6.0.13 (although I've seen the same issue
on Tomcat 5).

Appears to be a class-loading issue.  Stack trace below.  Any advice
would be appreciated.

SEVERE: Servlet.service() for servlet default threw exception
java.lang.NoSuchMethodError:
com.sun.org.apache.xerces.internal.parsers.XML11Configuration.getFeature
0(Ljava/lang/String;)Z
at
com.sun.org.apache.xerces.internal.parsers.XIncludeAwareParserConfigurat
ion.getFeature(XIncludeAwareParserConfiguration.java:278)
at
com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.reset(Abstr
actSAXParser.java:2098)
at
com.sun.org.apache.xerces.internal.parsers.XMLParser.parse(XMLParser.jav
a:147)
at
com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.parse(Abstr
actSAXParser.java:1242)
at
org.apache.tapestry.internal.services.TemplateParserImpl.parseTemplate(T
emplateParserImpl.java:173)
at
$TemplateParser_112ddb2276b.parseTemplate($TemplateParser_112ddb2276b.ja
va)
at
$TemplateParser_112ddb22764.parseTemplate($TemplateParser_112ddb22764.ja
va)
at
org.apache.tapestry.internal.services.ComponentTemplateSourceImpl.parseT
emplate(ComponentTemplateSourceImpl.java:145)
at
org.apache.tapestry.internal.services.ComponentTemplateSourceImpl.getTem
plate(ComponentTemplateSourceImpl.java:126)
at
$ComponentTemplateSource_112ddb22742.getTemplate($ComponentTemplateSourc
e_112ddb22742.java)
at
org.apache.tapestry.internal.services.PageLoaderProcessor.loadTemplateFo
rComponent(PageLoaderProcessor.java:427)
at
org.apache.tapestry.internal.services.PageLoaderProcessor.workComponentQ
ueue(PageLoaderProcessor.java:720)
at
org.apache.tapestry.internal.services.PageLoaderProcessor.loadPage(PageL
oaderProcessor.java:393)
at
org.apache.tapestry.internal.services.PageLoaderImpl.loadPage(PageLoader
Impl.java:59)
at
$PageLoader_112ddb2275f.loadPage($PageLoader_112ddb2275f.java)
at
org.apache.tapestry.internal.services.PagePoolImpl.checkout(PagePoolImpl
.java:63)
at $PagePool_112ddb2275e.checkout($PagePool_112ddb2275e.java)
at
org.apache.tapestry.internal.services.RequestPageCacheImpl.getByClassNam
e(RequestPageCacheImpl.java:58)
at
org.apache.tapestry.internal.services.RequestPageCacheImpl.get(RequestPa
geCacheImpl.java:49)
at
$RequestPageCache_112ddb2275d.get($RequestPageCache_112ddb2275d.java)
at
$RequestPageCache_112ddb22738.get($RequestPageCache_112ddb22738.java)
at
org.apache.tapestry.internal.services.DefaultRequestExceptionHandler.han
dleRequestException(DefaultRequestExceptionHandler.java:52)
at
$RequestExceptionHandler_112ddb2274d.handleRequestException($RequestExce
ptionHandler_112ddb2274d.java)
at
org.apache.tapestry.services.TapestryModule$3.service(TapestryModule.jav
a:645)
at
$RequestHandler_112ddb22750.service($RequestHandler_112ddb22750.java)
at
org.apache.tapestry.internal.services.StaticFilesFilter.service(StaticFi
lesFilter.java:63)
at
$RequestHandler_112ddb22750.service($RequestHandler_112ddb22750.java)
at
org.apache.tapestry.internal.services.CheckForUpdatesFilter$2.invoke(Che
ckForUpdatesFilter.java:91)
at
org.apache.tapestry.internal.services.CheckForUpdatesFilter$2.invoke(Che
ckForUpdatesFilter.java:82)
at
org.apache.tapestry.ioc.internal.util.ConcurrentBarrier.withRead(Concurr
entBarrier.java:77)
at
org.apache.tapestry.internal.services.CheckForUpdatesFilter.service(Chec
kForUpdatesFilter.java:104)
at
$RequestHandler_112ddb22750.service($RequestHandler_112ddb22750.java)
at
$RequestHandler_112ddb2274a.service($RequestHandler_112ddb2274a.java)
at
org.apache.tapestry.services.TapestryModule$11.service(TapestryModule.ja
va:1014)
at
$HttpServletRequestHandler_112ddb22749.service($HttpServletRequestHandle
r_112ddb22749.java)
at
org.apache.tapestry.TapestryFilter.doFilter(TapestryFilter.java:134)
at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(Applica
tionFilterChain.java:235)
at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilt
erChain.java:206)
at
org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValv
e.java:230)
at
org.apache.catalina.core.StandardContextValve.invoke(StandardContextValv
e.java:175)
at
org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java
:128)
at
org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java
:104)
at
org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.
java:109)
at

Re: URGENT: T4.1.1 on Oracle OC4J 9.0.4, 10.1.2.xxx - Missing classpath resource '/dojo' issue

2007-05-30 Thread Jan Vissers

Reading specification of getResource() ...

http://java.sun.com/j2se/1.4.2/docs/api/java/lang/ClassLoader.html#getResource(java.lang.String)

Finds the resource with the given name. A resource is some data 
(images, audio, text, etc) that can be accessed by class code in a way 
that is independent of the location of the code.


What I am seeing here is that getResource(java.lang.String) on a 
directory contained in a jar file, will result in null (on OC4J 
9.0.4/10.1.2.xxx).
Does this mean that Oracle has taken spec very strictly and doesn't 
allow directories being get like this?


-J.

Jesse Kuhnert wrote:
I'm not sure.  Only the wonderful oracle java developers know for sure 
I'm

guessing.

You can try messing with that or searching oracle related things for
configuring / changing the classloader settings.  Tapestry will 
ultimately
defer class (and class resource) resolution up to whatever class 
loader it

is running in - so it clearly has to be something oracle is f$#-ing up -
again.

On 5/30/07, Jan Vissers [EMAIL PROTECTED] wrote:


The ClassLoader held by org.apache.hivemind.impl.DefaultClassResolver
has this:

[ClassLoader:
[[D:\ora\ocj10_1_2_0_2\j2ee\home\applications\eva\eva-
web-1.0.0\WEB-INF\classes],
[D:\ora\ocj10_1_2_0_2\j2ee\home\applications\eva\eva-
web-1.0.0\WEB-INF\lib\backport-util-concurrent-4.1.1.jar
archive],
[D:\ora\ocj10_1_2_0_2\j2ee\home\applications\eva\eva-
web-1.0.0\WEB-INF\lib\commons-codec-1.3.jar
archive],
[D:\ora\ocj10_1_2_0_2\j2ee\home\applications\eva\eva-
web-1.0.0\WEB-INF\lib\commons-io-1.3.1.jar
archive],
[D:\ora\ocj10_1_2_0_2\j2ee\home\applications\eva\eva-
web-1.0.0\WEB-INF\lib\commons-lang-2.2.jar
archive],
[D:\ora\ocj10_1_2_0_2\j2ee\home\applications\eva\eva-
web-1.0.0\WEB-INF\lib\commons-logging-1.0.3.jar
archive],
[D:\ora\ocj10_1_2_0_2\j2ee\home\applications\eva\eva-
web-1.0.0\WEB-INF\lib\hivemind-lib-1.1.1.jar
archive],
[D:\ora\ocj10_1_2_0_2\j2ee\home\applications\eva\eva-
web-1.0.0\WEB-INF\lib\hivemind-oc4j-1.1.1.jar
archive],
[D:\ora\ocj10_1_2_0_2\j2ee\home\applications\eva\eva-
web-1.0.0\WEB-INF\lib\jakarta-oro-2.0.8.jar
archive],
[D:\ora\ocj10_1_2_0_2\j2ee\home\applications\eva\eva-
web-1.0.0\WEB-INF\lib\javassist-3.0.jar
archive],
[D:\ora\ocj10_1_2_0_2\j2ee\home\applications\eva\eva-
web-1.0.0\WEB-INF\lib\ognl-2.6.9.jar
archive],
[D:\ora\ocj10_1_2_0_2\j2ee\home\applications\eva\eva-
web-1.0.0\WEB-INF\lib\tapestry-framework-4.1.1.jar
archive]]]

'/dojo/' is in tapestry-framework-4.1.1.jar - maybe I am missing some
basic understanding here, but
why the hell is '/dojo' not found?

-J.


Jan Vissers wrote:
 Well - okay then...
 let me rephrase my question - is there any known record of people
 using T4.1.1 on OC4J 9.0.4 or OC4J 10.1.2.xxx

 Thx,
 -J.

 Jesse Kuhnert wrote:
 Yep.  Sounds like oracle is messing with your classloader.   I love
 oracle
 java software.  I love oracle java software.

 On 5/30/07, Jan Vissers [EMAIL PROTECTED] wrote:

 Digging deeper, and deeper...

 In DefaultClassResolver this method:

 public URL getResource(String name)
 {
 String stripped = removeLeadingSlash(name);

 URL result = _loader.getResource(stripped);

 return result;
 }

 returns null for 'dojo/' ...
 smells like a class loading issue, doesn't it

 any ideas?
 -J.

 Jan Vissers wrote:
  Checking the (Tapestry) code:
 
  public IAsset createAbsoluteAsset(String path, Locale locale,
 Location
  location)
 {
 Resource base = new ClasspathResource(_classResolver, 
path);

 Resource localized = _localizer.findLocalization(base,
 locale);
 
 if (localized == null)
 throw new
  ApplicationRuntimeException(AssetMessages.missingClasspathResource
 (path),
 location, null);
 
 return createAsset(localized, location);
 }
 
  _localizer.findLocalization(base, locale);
  Returns null for '/dojo' ... why would this happen?
 
  Thanks,
  -J.
 
  Jan Vissers wrote:
  Hi,
 
  I'm starting a new project for a customer of ours and want to use
  Tapestry 4.1.1 on Oracle's J2EE container - OC4J.
  Having tested various aspects of this T version on 10.1.3 - I'm
  pretty keen on using this version, however there are issues...
 
  Firstly I ran into a known issue with Hivemind's URLResource
 class on
  OC4J 9.0.4/10.1.2.xxx.
  I used a proposed hack to fix this issue. But now when I drop a
 Shell
  component on a form, I get this error:
 
  Caused by: org.apache.hivemind.ApplicationRuntimeException: 
Missing

  classpath resource '/dojo/'.
  [classpath:/org/apache/tapestry/html/Shell.jwc, line 179, column
61]
  at
  
org.apache.tapestry.asset.ClasspathAssetFactory.createAbsoluteAsset

(
 ClasspathAssetFactory.java:61)
 
  at
 

$AssetFactory_112dd0124f3.createAbsoluteAsset($AssetFactory_112dd0124f3.java) 



 
  at
  org.apache.tapestry.asset.AssetSourceImpl.findAsset(
 AssetSourceImpl.java:84)
 
  at
 $AssetSource_112dd0124a7.findAsset($AssetSource_112dd0124a7.java)

T5 Borders for components

2007-05-30 Thread Daniel Jue

Just a FYI,
this seems to work well, although the code surrounding the component
looks better when you replace these lines in your components'
templates:

html xmlns:t=http://tapestry.apache.org/schema/tapestry_5_0_0.xsd;
head
/head
body

...content here...

/body
/html


with this:

t:inputcomponentborder
xmlns:t=http://tapestry.apache.org/schema/tapestry_5_0_0.xsd;

...content here...

/t:inputcomponentborder


Where inputcomponentborder is the border component you want around
another component.  I am using this method to wrap a bunch of
components that just have small input forms on them.  The component
embeds them in a table with a bg image, etc.

You'll still have an html, head and body tag from the
inputcomponentborder, which might be fixed by Howard later.

Note: this is in addition to a border component that is used for the
page housing the components.

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: URGENT: T4.1.1 on Oracle OC4J 9.0.4, 10.1.2.xxx - Missing classpath resource '/dojo' issue

2007-05-30 Thread Jesse Kuhnert

I would say that oracle hasn't interpreted the specification strictly but
incorrectly.  Ie they are wrong and fuc#$ up - again.

I've been doing this kind of resource loading for years - loading icons and
such from swing applications as well as variety of others.  I've managed to
keep oracle out of my software except when it comes to storing/retrieving
relational data so I've not ever run in to this problem.

On 5/30/07, Jan Vissers [EMAIL PROTECTED] wrote:


Reading specification of getResource() ...


http://java.sun.com/j2se/1.4.2/docs/api/java/lang/ClassLoader.html#getResource(java.lang.String)

Finds the resource with the given name. A resource is some data
(images, audio, text, etc) that can be accessed by class code in a way
that is independent of the location of the code.

What I am seeing here is that getResource(java.lang.String) on a
directory contained in a jar file, will result in null (on OC4J
9.0.4/10.1.2.xxx).
Does this mean that Oracle has taken spec very strictly and doesn't
allow directories being get like this?

-J.

Jesse Kuhnert wrote:
 I'm not sure.  Only the wonderful oracle java developers know for sure
 I'm
 guessing.

 You can try messing with that or searching oracle related things for
 configuring / changing the classloader settings.  Tapestry will
 ultimately
 defer class (and class resource) resolution up to whatever class
 loader it
 is running in - so it clearly has to be something oracle is f$#-ing up -
 again.

 On 5/30/07, Jan Vissers [EMAIL PROTECTED] wrote:

 The ClassLoader held by org.apache.hivemind.impl.DefaultClassResolver
 has this:

 [ClassLoader:
 [[D:\ora\ocj10_1_2_0_2\j2ee\home\applications\eva\eva-
 web-1.0.0\WEB-INF\classes],
 [D:\ora\ocj10_1_2_0_2\j2ee\home\applications\eva\eva-
 web-1.0.0\WEB-INF\lib\backport-util-concurrent-4.1.1.jar
 archive],
 [D:\ora\ocj10_1_2_0_2\j2ee\home\applications\eva\eva-
 web-1.0.0\WEB-INF\lib\commons-codec-1.3.jar
 archive],
 [D:\ora\ocj10_1_2_0_2\j2ee\home\applications\eva\eva-
 web-1.0.0\WEB-INF\lib\commons-io-1.3.1.jar
 archive],
 [D:\ora\ocj10_1_2_0_2\j2ee\home\applications\eva\eva-
 web-1.0.0\WEB-INF\lib\commons-lang-2.2.jar
 archive],
 [D:\ora\ocj10_1_2_0_2\j2ee\home\applications\eva\eva-
 web-1.0.0\WEB-INF\lib\commons-logging-1.0.3.jar
 archive],
 [D:\ora\ocj10_1_2_0_2\j2ee\home\applications\eva\eva-
 web-1.0.0\WEB-INF\lib\hivemind-lib-1.1.1.jar
 archive],
 [D:\ora\ocj10_1_2_0_2\j2ee\home\applications\eva\eva-
 web-1.0.0\WEB-INF\lib\hivemind-oc4j-1.1.1.jar
 archive],
 [D:\ora\ocj10_1_2_0_2\j2ee\home\applications\eva\eva-
 web-1.0.0\WEB-INF\lib\jakarta-oro-2.0.8.jar
 archive],
 [D:\ora\ocj10_1_2_0_2\j2ee\home\applications\eva\eva-
 web-1.0.0\WEB-INF\lib\javassist-3.0.jar
 archive],
 [D:\ora\ocj10_1_2_0_2\j2ee\home\applications\eva\eva-
 web-1.0.0\WEB-INF\lib\ognl-2.6.9.jar
 archive],
 [D:\ora\ocj10_1_2_0_2\j2ee\home\applications\eva\eva-
 web-1.0.0\WEB-INF\lib\tapestry-framework-4.1.1.jar
 archive]]]

 '/dojo/' is in tapestry-framework-4.1.1.jar - maybe I am missing some
 basic understanding here, but
 why the hell is '/dojo' not found?

 -J.


 Jan Vissers wrote:
  Well - okay then...
  let me rephrase my question - is there any known record of people
  using T4.1.1 on OC4J 9.0.4 or OC4J 10.1.2.xxx
 
  Thx,
  -J.
 
  Jesse Kuhnert wrote:
  Yep.  Sounds like oracle is messing with your classloader.   I love
  oracle
  java software.  I love oracle java software.
 
  On 5/30/07, Jan Vissers [EMAIL PROTECTED] wrote:
 
  Digging deeper, and deeper...
 
  In DefaultClassResolver this method:
 
  public URL getResource(String name)
  {
  String stripped = removeLeadingSlash(name);
 
  URL result = _loader.getResource(stripped);
 
  return result;
  }
 
  returns null for 'dojo/' ...
  smells like a class loading issue, doesn't it
 
  any ideas?
  -J.
 
  Jan Vissers wrote:
   Checking the (Tapestry) code:
  
   public IAsset createAbsoluteAsset(String path, Locale locale,
  Location
   location)
  {
  Resource base = new ClasspathResource(_classResolver,
 path);
  Resource localized = _localizer.findLocalization(base,
  locale);
  
  if (localized == null)
  throw new
   ApplicationRuntimeException(
AssetMessages.missingClasspathResource
  (path),
  location, null);
  
  return createAsset(localized, location);
  }
  
   _localizer.findLocalization(base, locale);
   Returns null for '/dojo' ... why would this happen?
  
   Thanks,
   -J.
  
   Jan Vissers wrote:
   Hi,
  
   I'm starting a new project for a customer of ours and want to
use
   Tapestry 4.1.1 on Oracle's J2EE container - OC4J.
   Having tested various aspects of this T version on 10.1.3 - I'm
   pretty keen on using this version, however there are issues...
  
   Firstly I ran into a known issue with Hivemind's URLResource
  class on
   OC4J 9.0.4/10.1.2.xxx.
   I used a proposed hack to fix this issue. But now when I drop a
  Shell
   component on a 

Re: URGENT: T4.1.1 on Oracle OC4J 9.0.4, 10.1.2.xxx - Missing classpath resource '/dojo' issue

2007-05-30 Thread Jan Vissers
I've been doing this kind of resource loading for years - loading 
icons and

such from swing applications as well as variety of others.

Ok - but these are in fact examples of individual files,
could it be that 'directories' have been interpreted differently by this 
implementation?


And... is the '/dojo/' case on-of-a-kind of such a directory needing to 
be loaded?


I've managed to keep oracle out of my software except when it comes to
storing/retrieving relational data so I've not ever run in to this 
problem.


Not to offend you in any kind of way - but this is a luxury not 
everybody has, what's
more it kinda violates a principle of Java/J2EE. The fact that in this 
case the problem is
probably caused by the application server vendor is obviously a totally 
different thing -
but I hope you're aware that we (Oracle OC4J users) also would like to 
use a beautiful framework


Thx,
-J.

Jesse Kuhnert wrote:

I would say that oracle hasn't interpreted the specification strictly but
incorrectly.  Ie they are wrong and fuc#$ up - again.

I've been doing this kind of resource loading for years - loading 
icons and
such from swing applications as well as variety of others.  I've 
managed to

keep oracle out of my software except when it comes to storing/retrieving
relational data so I've not ever run in to this problem.

On 5/30/07, Jan Vissers [EMAIL PROTECTED] wrote:


Reading specification of getResource() ...


http://java.sun.com/j2se/1.4.2/docs/api/java/lang/ClassLoader.html#getResource(java.lang.String) 



Finds the resource with the given name. A resource is some data
(images, audio, text, etc) that can be accessed by class code in a way
that is independent of the location of the code.

What I am seeing here is that getResource(java.lang.String) on a
directory contained in a jar file, will result in null (on OC4J
9.0.4/10.1.2.xxx).
Does this mean that Oracle has taken spec very strictly and doesn't
allow directories being get like this?

-J.

Jesse Kuhnert wrote:
 I'm not sure.  Only the wonderful oracle java developers know for sure
 I'm
 guessing.

 You can try messing with that or searching oracle related things for
 configuring / changing the classloader settings.  Tapestry will
 ultimately
 defer class (and class resource) resolution up to whatever class
 loader it
 is running in - so it clearly has to be something oracle is f$#-ing 
up -

 again.

 On 5/30/07, Jan Vissers [EMAIL PROTECTED] wrote:

 The ClassLoader held by org.apache.hivemind.impl.DefaultClassResolver
 has this:

 [ClassLoader:
 [[D:\ora\ocj10_1_2_0_2\j2ee\home\applications\eva\eva-
 web-1.0.0\WEB-INF\classes],
 [D:\ora\ocj10_1_2_0_2\j2ee\home\applications\eva\eva-
 web-1.0.0\WEB-INF\lib\backport-util-concurrent-4.1.1.jar
 archive],
 [D:\ora\ocj10_1_2_0_2\j2ee\home\applications\eva\eva-
 web-1.0.0\WEB-INF\lib\commons-codec-1.3.jar
 archive],
 [D:\ora\ocj10_1_2_0_2\j2ee\home\applications\eva\eva-
 web-1.0.0\WEB-INF\lib\commons-io-1.3.1.jar
 archive],
 [D:\ora\ocj10_1_2_0_2\j2ee\home\applications\eva\eva-
 web-1.0.0\WEB-INF\lib\commons-lang-2.2.jar
 archive],
 [D:\ora\ocj10_1_2_0_2\j2ee\home\applications\eva\eva-
 web-1.0.0\WEB-INF\lib\commons-logging-1.0.3.jar
 archive],
 [D:\ora\ocj10_1_2_0_2\j2ee\home\applications\eva\eva-
 web-1.0.0\WEB-INF\lib\hivemind-lib-1.1.1.jar
 archive],
 [D:\ora\ocj10_1_2_0_2\j2ee\home\applications\eva\eva-
 web-1.0.0\WEB-INF\lib\hivemind-oc4j-1.1.1.jar
 archive],
 [D:\ora\ocj10_1_2_0_2\j2ee\home\applications\eva\eva-
 web-1.0.0\WEB-INF\lib\jakarta-oro-2.0.8.jar
 archive],
 [D:\ora\ocj10_1_2_0_2\j2ee\home\applications\eva\eva-
 web-1.0.0\WEB-INF\lib\javassist-3.0.jar
 archive],
 [D:\ora\ocj10_1_2_0_2\j2ee\home\applications\eva\eva-
 web-1.0.0\WEB-INF\lib\ognl-2.6.9.jar
 archive],
 [D:\ora\ocj10_1_2_0_2\j2ee\home\applications\eva\eva-
 web-1.0.0\WEB-INF\lib\tapestry-framework-4.1.1.jar
 archive]]]

 '/dojo/' is in tapestry-framework-4.1.1.jar - maybe I am missing some
 basic understanding here, but
 why the hell is '/dojo' not found?

 -J.


 Jan Vissers wrote:
  Well - okay then...
  let me rephrase my question - is there any known record of people
  using T4.1.1 on OC4J 9.0.4 or OC4J 10.1.2.xxx
 
  Thx,
  -J.
 
  Jesse Kuhnert wrote:
  Yep.  Sounds like oracle is messing with your classloader.   I 
love

  oracle
  java software.  I love oracle java software.
 
  On 5/30/07, Jan Vissers [EMAIL PROTECTED] wrote:
 
  Digging deeper, and deeper...
 
  In DefaultClassResolver this method:
 
  public URL getResource(String name)
  {
  String stripped = removeLeadingSlash(name);
 
  URL result = _loader.getResource(stripped);
 
  return result;
  }
 
  returns null for 'dojo/' ...
  smells like a class loading issue, doesn't it
 
  any ideas?
  -J.
 
  Jan Vissers wrote:
   Checking the (Tapestry) code:
  
   public IAsset createAbsoluteAsset(String path, Locale locale,
  Location
   location)
  {
  Resource base = new ClasspathResource(_classResolver,
 

Re: t5: Date input component

2007-05-30 Thread Marcus

Hi Juan,

First, Good job.
after, some questions:

Where can i download?
com.dodo.community.web.util.SelectModelUtil
com.dodo.util.DateUtils

What about ClientElement interface?

Thanks

Marcus


Re: t5: Date input component

2007-05-30 Thread Matt Kerr
Hey Juan -

umm ... 2 cents..
if you have a minute, maybe let me know what i'm missing ..
(thanks!)

Here is the DateInput component for t5:
http://juanemaya.blogspot.com/2007/05/tapestry-5-date-input-component.html
I am not sure if that's the best way to do it. I think that building the
date in the year set is not the best way but well, i am learning slowly :)

I'd have to check the T5 docs(?), but I thought in T4 (and prior?) .. that you 
were *not* guaranteed to have your set'ers called in any specific order (e.g 
Year, Month, Day .. or Day, Month, Year, .. or whatever)

So, if this works, it's just by chance.

~~
public void setYear(String year) {
this.year = year;
setValue(DateUtils.buildDate(Integer.parseInt(month), Integer.parseInt(day), 
Integer.parseInt(year)));
}
~~

Can anyone confirm or deny ?


It's also kind of unsavory -- since, well, it's kind of subtle hidden there in 
setYear().

Isn't there a well-defined point in time (e.g. a callback method) which is 
invoked by the framework to let you know ..
Hey!  The request has been process .. and your Component's ivars are set now 
.. so, go ahead and perform your Component's action, like setValue()

Versus .. always placing the Component's *real* beahiovor in the bottom half of 
the last accessor ?
Doesn't that seem strange - ?

If that's the case .. there seems little separation between the .html and the 
.java code :-((
(E.g you can change the order of your .html (Year/Month/Day - Month/Day/Year) 
.. and that will *break* your component :-O !!)
That's the complete opposite of why you separate out presentation from logic -- 
they're not supposed to affect each other.

I think you need a listener method or some such.

I'm reading through the Tap4 docs -
  http://tapestry.apache.org/tapestry4/UsersGuide/

But where's the section on Request Processing?
eg. what happens when someone submits a FORM?
Or examples of simple form processing ..

Thanks,sl



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: t5: Date input component

2007-05-30 Thread Juan Maya

Hi Matt. Yes, i am already aware of this problem and reading how to do it in
T5. If anybody has any suggestions i will appreciate it.


On 5/30/07, Matt Kerr [EMAIL PROTECTED] wrote:


Hey Juan -

umm ... 2 cents..
if you have a minute, maybe let me know what i'm missing ..
(thanks!)

Here is the DateInput component for t5:

http://juanemaya.blogspot.com/2007/05/tapestry-5-date-input-component.html
I am not sure if that's the best way to do it. I think that building the
date in the year set is not the best way but well, i am learning slowly
:)

I'd have to check the T5 docs(?), but I thought in T4 (and prior?) .. that
you were *not* guaranteed to have your set'ers called in any specific order
(e.g Year, Month, Day .. or Day, Month, Year, .. or whatever)

So, if this works, it's just by chance.

~~
public void setYear(String year) {
this.year = year;
setValue(DateUtils.buildDate(Integer.parseInt(month), Integer.parseInt(day),
Integer.parseInt(year)));
}
~~

Can anyone confirm or deny ?


It's also kind of unsavory -- since, well, it's kind of subtle hidden
there in setYear().

Isn't there a well-defined point in time (e.g. a callback method) which is
invoked by the framework to let you know ..
Hey!  The request has been process .. and your Component's ivars are set
now .. so, go ahead and perform your Component's action, like setValue()

Versus .. always placing the Component's *real* beahiovor in the bottom
half of the last accessor ?
Doesn't that seem strange - ?

If that's the case .. there seems little separation between the .html and
the .java code :-((
(E.g you can change the order of your .html (Year/Month/Day -
Month/Day/Year) .. and that will *break* your component :-O !!)
That's the complete opposite of why you separate out presentation from
logic -- they're not supposed to affect each other.

I think you need a listener method or some such.

I'm reading through the Tap4 docs -
  http://tapestry.apache.org/tapestry4/UsersGuide/

But where's the section on Request Processing?
eg. what happens when someone submits a FORM?
Or examples of simple form processing ..

Thanks,sl



-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




Re: t5: Date input component

2007-05-30 Thread Juan Maya

sorry marcus. I just added the code to the blog. Anyway this is the link:
http://www.geocities.com/jmayaalv/DateInput.zip

ClientElement is T5 interface.

On 5/30/07, Marcus [EMAIL PROTECTED] wrote:


Hi Juan,

First, Good job.
after, some questions:

Where can i download?
com.dodo.community.web.util.SelectModelUtil
com.dodo.util.DateUtils

What about ClientElement interface?

Thanks

Marcus



Re: URGENT: T4.1.1 on Oracle OC4J 9.0.4, 10.1.2.xxx - Missing classpath resource '/dojo' issue

2007-05-30 Thread Jan Vissers

10.1.3 returns
code-source:/D:/ora/ocj10_1_3_2_0/j2ee/home/applications/KLPD-Eva/eva-web-1.0.0/WEB-INF/lib/tapestry-framework-4.1.1.jar!/dojo/
for '/dojo' - which in plain english means, it works ok.

I notice that this version of OC4J uses a different classloader: 
oracle.classloader.PolicyClassLoader
which is a result of the massively changed class loading functionality 
in 10.1.3.


I'm thinking about filing a service request/bug with Oracle, but don't 
think it'll make an impression on them.


-J.

Jan Vissers wrote:
I've been doing this kind of resource loading for years - loading 
icons and

such from swing applications as well as variety of others.

Ok - but these are in fact examples of individual files,
could it be that 'directories' have been interpreted differently by 
this implementation?


And... is the '/dojo/' case on-of-a-kind of such a directory needing 
to be loaded?


I've managed to keep oracle out of my software except when it comes to
storing/retrieving relational data so I've not ever run in to this 
problem.


Not to offend you in any kind of way - but this is a luxury not 
everybody has, what's
more it kinda violates a principle of Java/J2EE. The fact that in this 
case the problem is
probably caused by the application server vendor is obviously a 
totally different thing -
but I hope you're aware that we (Oracle OC4J users) also would like to 
use a beautiful framework


Thx,
-J.

Jesse Kuhnert wrote:
I would say that oracle hasn't interpreted the specification strictly 
but

incorrectly.  Ie they are wrong and fuc#$ up - again.

I've been doing this kind of resource loading for years - loading 
icons and
such from swing applications as well as variety of others.  I've 
managed to
keep oracle out of my software except when it comes to 
storing/retrieving

relational data so I've not ever run in to this problem.

On 5/30/07, Jan Vissers [EMAIL PROTECTED] wrote:


Reading specification of getResource() ...


http://java.sun.com/j2se/1.4.2/docs/api/java/lang/ClassLoader.html#getResource(java.lang.String) 



Finds the resource with the given name. A resource is some data
(images, audio, text, etc) that can be accessed by class code in a way
that is independent of the location of the code.

What I am seeing here is that getResource(java.lang.String) on a
directory contained in a jar file, will result in null (on OC4J
9.0.4/10.1.2.xxx).
Does this mean that Oracle has taken spec very strictly and doesn't
allow directories being get like this?

-J.

Jesse Kuhnert wrote:
 I'm not sure.  Only the wonderful oracle java developers know for 
sure

 I'm
 guessing.

 You can try messing with that or searching oracle related things for
 configuring / changing the classloader settings.  Tapestry will
 ultimately
 defer class (and class resource) resolution up to whatever class
 loader it
 is running in - so it clearly has to be something oracle is 
f$#-ing up -

 again.

 On 5/30/07, Jan Vissers [EMAIL PROTECTED] wrote:

 The ClassLoader held by 
org.apache.hivemind.impl.DefaultClassResolver

 has this:

 [ClassLoader:
 [[D:\ora\ocj10_1_2_0_2\j2ee\home\applications\eva\eva-
 web-1.0.0\WEB-INF\classes],
 [D:\ora\ocj10_1_2_0_2\j2ee\home\applications\eva\eva-
 web-1.0.0\WEB-INF\lib\backport-util-concurrent-4.1.1.jar
 archive],
 [D:\ora\ocj10_1_2_0_2\j2ee\home\applications\eva\eva-
 web-1.0.0\WEB-INF\lib\commons-codec-1.3.jar
 archive],
 [D:\ora\ocj10_1_2_0_2\j2ee\home\applications\eva\eva-
 web-1.0.0\WEB-INF\lib\commons-io-1.3.1.jar
 archive],
 [D:\ora\ocj10_1_2_0_2\j2ee\home\applications\eva\eva-
 web-1.0.0\WEB-INF\lib\commons-lang-2.2.jar
 archive],
 [D:\ora\ocj10_1_2_0_2\j2ee\home\applications\eva\eva-
 web-1.0.0\WEB-INF\lib\commons-logging-1.0.3.jar
 archive],
 [D:\ora\ocj10_1_2_0_2\j2ee\home\applications\eva\eva-
 web-1.0.0\WEB-INF\lib\hivemind-lib-1.1.1.jar
 archive],
 [D:\ora\ocj10_1_2_0_2\j2ee\home\applications\eva\eva-
 web-1.0.0\WEB-INF\lib\hivemind-oc4j-1.1.1.jar
 archive],
 [D:\ora\ocj10_1_2_0_2\j2ee\home\applications\eva\eva-
 web-1.0.0\WEB-INF\lib\jakarta-oro-2.0.8.jar
 archive],
 [D:\ora\ocj10_1_2_0_2\j2ee\home\applications\eva\eva-
 web-1.0.0\WEB-INF\lib\javassist-3.0.jar
 archive],
 [D:\ora\ocj10_1_2_0_2\j2ee\home\applications\eva\eva-
 web-1.0.0\WEB-INF\lib\ognl-2.6.9.jar
 archive],
 [D:\ora\ocj10_1_2_0_2\j2ee\home\applications\eva\eva-
 web-1.0.0\WEB-INF\lib\tapestry-framework-4.1.1.jar
 archive]]]

 '/dojo/' is in tapestry-framework-4.1.1.jar - maybe I am missing 
some

 basic understanding here, but
 why the hell is '/dojo' not found?

 -J.


 Jan Vissers wrote:
  Well - okay then...
  let me rephrase my question - is there any known record of people
  using T4.1.1 on OC4J 9.0.4 or OC4J 10.1.2.xxx
 
  Thx,
  -J.
 
  Jesse Kuhnert wrote:
  Yep.  Sounds like oracle is messing with your classloader.   I 
love

  oracle
  java software.  I love oracle java software.
 
  On 5/30/07, Jan Vissers [EMAIL PROTECTED] wrote:
 
  Digging deeper, and deeper...
 
  In 

T5.0.5 delegate rendering before other components

2007-05-30 Thread Daniel Jue

Hi, not sure if this is a problem or intended behavior:
I have a t:block at the bottom of my template, but still inside the body.

If I have this in a table,
tdt:selectsessionleveltype /t:delegate to=typeOfSesionLevel //td
where typeOfSesionLevel returns a block,  The block rendered by
typeOfSesionLevel gets rendered before the component
selectsessionleveltype.


Of course I can force it to appear in the order I intended, but I
could see this being an issue if, say, we were rendering bits and
pieces of a large image using components and blocks.

tdt:selectsessionleveltype //td tdt:delegate
to=typeOfSesionLevel 
//td

Daniel

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: URGENT: T4.1.1 on Oracle OC4J 9.0.4, 10.1.2.xxx - Missing classpath resource '/dojo' issue

2007-05-30 Thread Jesse Kuhnert

Good luck. ;)

p.s. You can always just switch to software not written by bad programmers -
like jboss or something.  It must work reasonably well if it's good enough
for google.

On 5/30/07, Jan Vissers [EMAIL PROTECTED] wrote:


snipped/

I'm thinking about filing a service request/bug with Oracle, but don't
think it'll make an impression on them.

-J.
snipped/





--
Jesse Kuhnert
Tapestry/Dojo team member/developer

Open source based consulting work centered around
dojo/tapestry/tacos/hivemind. http://blog.opencomponentry.com


Re: T5: Works in Jetty but not in Tomcat

2007-05-30 Thread Marcus

Hi,

For us T5 works fine with Tomcat or Jetty.

mvn tomcat:run  (inside app dir)

or build war file and deploy:

mvn war:war  (inside app dir, war will be in appdir/target)

Marcus


Re: scrolling window : dojo dialog vs thickbox

2007-05-30 Thread Jesse Kuhnert

I'd love to be able to support jquery / others as addition javascript
handlers.  ...Perhaps this is something we can address in the 4.1.3 dev
cycle.

On 5/29/07, Paul Stanton [EMAIL PROTECTED] wrote:


(4.1.1)

I'm using a dojo dialog to dynamically display a form. I've noticed that
when I scroll the page (browser scroll) while the form is displayed, the
shadow does not take up the whole page (momentarily) ie you can see
white at the top or bottom of the page instead of the tint. Also the
dialog vibrates up and down as the page is scrolled, which is obviously
some reposition calculation being run in the onscroll event handling.

I've noticed that thickbox works 100% in this regard, it scrolls
smoothly and the tint does not change.

any one else noticed this? is there a dojo upgrade?


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]





--
Jesse Kuhnert
Tapestry/Dojo team member/developer

Open source based consulting work centered around
dojo/tapestry/tacos/hivemind. http://blog.opencomponentry.com


Re: T5: Works in Jetty but not in Tomcat

2007-05-30 Thread Marcus

Check this:

in POM.XML, use
tapestry-release-version5.0.5-SNAPSHOT/tapestry-release-version
or
tapestry-release-version5.0.4/tapestry-release-version


the command mvn jetty:run works?


RE: T5: Works in Jetty but not in Tomcat

2007-05-30 Thread Joel Wiegman
Marcus,

Thanks for the reply.  I've been able to get it to work with mvn
tomcat:run and mvn jetty:run, but not by deploying the war to a separate
instance of Tomcat.  I'll keep at it.  It's not looking like it's a
Tapestry bug... it appears to be a classloading issue involving
JAXP/Xerces.

Cheers,

Joel
 

-Original Message-
From: Marcus [mailto:[EMAIL PROTECTED] 
Sent: Wednesday, May 30, 2007 1:55 PM
To: Tapestry users
Subject: Re: T5: Works in Jetty but not in Tomcat

Hi,

For us T5 works fine with Tomcat or Jetty.

mvn tomcat:run  (inside app dir)

or build war file and deploy:

mvn war:war  (inside app dir, war will be in appdir/target)

Marcus

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: t5: Date input component

2007-05-30 Thread Juan Maya

:) I created a Callback registered @afterRender inside DateInput.java and
that did  the trick!
thanks a lot for your suggestions Mark!

(the post and code in my blog already has all changes)

On 5/30/07, Juan Maya [EMAIL PROTECTED] wrote:


Hi Matt. Yes, i am already aware of this problem and reading how to do it
in T5. If anybody has any suggestions i will appreciate it.


On 5/30/07, Matt Kerr [EMAIL PROTECTED] wrote:

 Hey Juan -

 umm ... 2 cents..
 if you have a minute, maybe let me know what i'm missing ..
 (thanks!)

 Here is the DateInput component for t5:
 http://juanemaya.blogspot.com/2007/05/tapestry-5-date-input-component.html
 I am not sure if that's the best way to do it. I think that building
 the
 date in the year set is not the best way but well, i am learning slowly
 :)

 I'd have to check the T5 docs(?), but I thought in T4 (and prior?) ..
 that you were *not* guaranteed to have your set'ers called in any specific
 order (e.g Year, Month, Day .. or Day, Month, Year, .. or whatever)

 So, if this works, it's just by chance.

 ~~
 public void setYear(String year) {
 this.year = year;
 setValue(DateUtils.buildDate(Integer.parseInt(month), Integer.parseInt(day),
 Integer.parseInt(year)));
 }
 ~~

 Can anyone confirm or deny ?


 It's also kind of unsavory -- since, well, it's kind of subtle hidden
 there in setYear().

 Isn't there a well-defined point in time (e.g. a callback method) which
 is invoked by the framework to let you know ..
 Hey!  The request has been process .. and your Component's ivars are
 set now .. so, go ahead and perform your Component's action, like
 setValue()

 Versus .. always placing the Component's *real* beahiovor in the bottom
 half of the last accessor ?
 Doesn't that seem strange - ?

 If that's the case .. there seems little separation between the .html
 and the .java code :-((
 (E.g you can change the order of your .html (Year/Month/Day -
 Month/Day/Year) .. and that will *break* your component :-O !!)
 That's the complete opposite of why you separate out presentation from
 logic -- they're not supposed to affect each other.

 I think you need a listener method or some such.

 I'm reading through the Tap4 docs -
   http://tapestry.apache.org/tapestry4/UsersGuide/

 But where's the section on Request Processing?
 eg. what happens when someone submits a FORM?
 Or examples of simple form processing ..

 Thanks,sl



 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]





Re: t5: Date input component

2007-05-30 Thread Marcus

Juan,
Don't forget to complete, in your blog:

You can use the component like this:
.


Re: t5: Date input component

2007-05-30 Thread Juan Maya

Done.
Thanks.

On 5/30/07, Marcus [EMAIL PROTECTED] wrote:


Juan,
Don't forget to complete, in your blog:

You can use the component like this:
.



RE: T5: Works in Jetty but not in Tomcat

2007-05-30 Thread Jonathan Glanz
A trick to make it all work is to explode the tapestry jars into
WEB-INF/classes

-It does workbut it can get messy

-Jon

-Original Message-
From: Joel Wiegman [mailto:[EMAIL PROTECTED] 
Sent: Wednesday, May 30, 2007 11:48 AM
To: Tapestry users
Subject: RE: T5: Works in Jetty but not in Tomcat

Marcus,

Thanks for the reply.  I've been able to get it to work with mvn
tomcat:run and mvn jetty:run, but not by deploying the war to a separate
instance of Tomcat.  I'll keep at it.  It's not looking like it's a
Tapestry bug... it appears to be a classloading issue involving
JAXP/Xerces.

Cheers,

Joel
 

-Original Message-
From: Marcus [mailto:[EMAIL PROTECTED] 
Sent: Wednesday, May 30, 2007 1:55 PM
To: Tapestry users
Subject: Re: T5: Works in Jetty but not in Tomcat

Hi,

For us T5 works fine with Tomcat or Jetty.

mvn tomcat:run  (inside app dir)

or build war file and deploy:

mvn war:war  (inside app dir, war will be in appdir/target)

Marcus

-
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]



Re: URGENT: T4.1.1 on Oracle OC4J 9.0.4, 10.1.2.xxx - Missing classpath resource '/dojo' issue

2007-05-30 Thread Andreas Andreou

You can make the Shell use a custom AjaxShellDelegate, here's the default
implementation

http://svn.apache.org/viewvc/tapestry/tapestry4/tags/4.1.1/tapestry-framework/src/java/org/apache/tapestry/dojo/AjaxShellDelegate.java?view=markup

btw, i'd go for the 4.1.2 version

On 5/30/07, Jan Vissers [EMAIL PROTECTED] wrote:


Okay - this might sound stupid...

It looks like this problem occurs when getResource() needs to get
'directories' within a library. More specifically in the Shell component:


http://svn.apache.org/viewvc/tapestry/tapestry4/tags/4.1.1/tapestry-framework/src/java/org/apache/tapestry/html/Shell.jwc?view=markup

asset name=defaultDojoPath path=classpath:/dojo/ /
asset name=defaultTapestryPath path=classpath:/tapestry/ /

When these assets are the only ones of their kind in the Tapestry
framework, couldn't I create a custom Shell component that declares these
assets in some other way?

Still hoping I can use 4.1.1 - that's why I'm not ready to give up yet.

-J.

 Good luck. ;)

 p.s. You can always just switch to software not written by bad
programmers
 -
 like jboss or something.  It must work reasonably well if it's good
enough
 for google.

 On 5/30/07, Jan Vissers [EMAIL PROTECTED] wrote:

 snipped/

 I'm thinking about filing a service request/bug with Oracle, but don't
 think it'll make an impression on them.

 -J.
 snipped/




 --
 Jesse Kuhnert
 Tapestry/Dojo team member/developer

 Open source based consulting work centered around
 dojo/tapestry/tacos/hivemind. http://blog.opencomponentry.com




-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]





--
Andreas Andreou - [EMAIL PROTECTED] - http://andyhot.di.uoa.gr
Tapestry / Tacos developer
Open Source / JEE Consulting


Re: URGENT: T4.1.1 on Oracle OC4J 9.0.4, 10.1.2.xxx - Missing classpath resource '/dojo' issue

2007-05-30 Thread Jan Vissers
Hi,

Thanks for your suggestion. I am wondering whether a custom
AjaxShellDelegate will effectively change the fact that the getResource()
to dojoPath and tapestryPath are called - as this is what causing me
problems at the moment.

Or to put in other words - will this be sufficient to make the problem go
away, or do I need to actually hack the hivemind code that performs te
getResource()?

-J.


 You can make the Shell use a custom AjaxShellDelegate, here's the default
 implementation

 http://svn.apache.org/viewvc/tapestry/tapestry4/tags/4.1.1/tapestry-framework/src/java/org/apache/tapestry/dojo/AjaxShellDelegate.java?view=markup

 btw, i'd go for the 4.1.2 version

 On 5/30/07, Jan Vissers [EMAIL PROTECTED] wrote:

 Okay - this might sound stupid...

 It looks like this problem occurs when getResource() needs to get
 'directories' within a library. More specifically in the Shell
 component:


 http://svn.apache.org/viewvc/tapestry/tapestry4/tags/4.1.1/tapestry-framework/src/java/org/apache/tapestry/html/Shell.jwc?view=markup

 asset name=defaultDojoPath path=classpath:/dojo/ /
 asset name=defaultTapestryPath path=classpath:/tapestry/ /

 When these assets are the only ones of their kind in the Tapestry
 framework, couldn't I create a custom Shell component that declares
 these
 assets in some other way?

 Still hoping I can use 4.1.1 - that's why I'm not ready to give up yet.

 -J.

  Good luck. ;)
 
  p.s. You can always just switch to software not written by bad
 programmers
  -
  like jboss or something.  It must work reasonably well if it's good
 enough
  for google.
 
  On 5/30/07, Jan Vissers [EMAIL PROTECTED] wrote:
 
  snipped/
 
  I'm thinking about filing a service request/bug with Oracle, but
 don't
  think it'll make an impression on them.
 
  -J.
  snipped/
 
 
 
 
  --
  Jesse Kuhnert
  Tapestry/Dojo team member/developer
 
  Open source based consulting work centered around
  dojo/tapestry/tacos/hivemind. http://blog.opencomponentry.com
 



 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]




 --
 Andreas Andreou - [EMAIL PROTECTED] - http://andyhot.di.uoa.gr
 Tapestry / Tacos developer
 Open Source / JEE Consulting




-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: T5: when is @Persist necessary and when not...

2007-05-30 Thread Howard Lewis Ship

There should not be any difference; I'd have to see your code to determine
what's going on.

On 5/30/07, Martin Dietze [EMAIL PROTECTED] wrote:


On Wed, May 30, 2007, Howard Lewis Ship wrote:

 I have a page class which keeps form data like this:
 
 | // class MyForm
 | private Person _person;
 | private String _homepage;
 
 The class Person consists of several fields:
 
 | // class Person
 | private String _firstName
 | private String _lastName
 
 For all these I have getters and setters defined.
 
 In my page class I have a constructor like this:
 
 | public CreatePartner() {
 |   _contact = new Person();
^^^ `person' of course!
 | }

[...]

 Tapestry uses a redirect-after-post for actions, including form submits.
 Thus if the data is stored persistently, usually in the HttpSession, it
is
 gone on the second request, the one that actually renders a response.

 If you used the debugger, you'd see that your _person field would also
be
 null in the second request, the render request. You just aren't using
it.

Interestingly this does not seem to be the case in my
application. Debugging the above class I find that when the
page is rendered after submit the `Person' object still
contains the submitted values.

Additionally `_$person_default' object (as I guess created by
T5) contains the values of the populated person object.

For the `_homeapage' object which is an ordinary String, the
values are lost unless I put a [EMAIL PROTECTED](flash)' above it
which should be expected according to your post. Now I wonder
why does the Person object seem to behave differently?

Cheers,

Martin

--
- / http://herbert.the-little-red-haired-girl.org /
-
=+=
The only intuitive interface is the nipple. After that, it's all
learned.  -- Bruce Ediger

-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]





--
Howard M. Lewis Ship
TWD Consulting, Inc.
Independent J2EE / Open-Source Java Consultant
Creator and PMC Chair, Apache Tapestry
Creator, Apache HiveMind

Professional Tapestry training, mentoring, support
and project work.  http://howardlewisship.com


Re: T5: when is @Persist necessary and when not...

2007-05-30 Thread Howard Lewis Ship

Just noticed your constructor. Don't do that.

The Person object that you create will become the default value for this
property, rather than null.  This is documented.

On 5/30/07, Howard Lewis Ship [EMAIL PROTECTED] wrote:


There should not be any difference; I'd have to see your code to determine
what's going on.

On 5/30/07, Martin Dietze  [EMAIL PROTECTED] wrote:

 On Wed, May 30, 2007, Howard Lewis Ship wrote:

  I have a page class which keeps form data like this:
  
  | // class MyForm
  | private Person _person;
  | private String _homepage;
  
  The class Person consists of several fields:
  
  | // class Person
  | private String _firstName
  | private String _lastName
  
  For all these I have getters and setters defined.
  
  In my page class I have a constructor like this:
  
  | public CreatePartner() {
  |   _contact = new Person();
 ^^^ `person' of course!
  | }

 [...]

  Tapestry uses a redirect-after-post for actions, including form
 submits.
  Thus if the data is stored persistently, usually in the HttpSession,
 it is
  gone on the second request, the one that actually renders a response.

  If you used the debugger, you'd see that your _person field would also
 be
  null in the second request, the render request. You just aren't using
 it.

 Interestingly this does not seem to be the case in my
 application. Debugging the above class I find that when the
 page is rendered after submit the `Person' object still
 contains the submitted values.

 Additionally `_$person_default' object (as I guess created by
 T5) contains the values of the populated person object.

 For the `_homeapage' object which is an ordinary String, the
 values are lost unless I put a [EMAIL PROTECTED](flash)' above it
 which should be expected according to your post. Now I wonder
 why does the Person object seem to behave differently?

 Cheers,

 Martin

 --
 - / http://herbert.the-little-red-haired-girl.org /
 -
 =+=
 The only intuitive interface is the nipple. After that, it's all
 learned.  -- Bruce Ediger

 -
 To unsubscribe, e-mail: [EMAIL PROTECTED]
 For additional commands, e-mail: [EMAIL PROTECTED]




--
Howard M. Lewis Ship
TWD Consulting, Inc.
Independent J2EE / Open-Source Java Consultant
Creator and PMC Chair, Apache Tapestry
Creator, Apache HiveMind

Professional Tapestry training, mentoring, support
and project work.   http://howardlewisship.com





--
Howard M. Lewis Ship
TWD Consulting, Inc.
Independent J2EE / Open-Source Java Consultant
Creator and PMC Chair, Apache Tapestry
Creator, Apache HiveMind

Professional Tapestry training, mentoring, support
and project work.  http://howardlewisship.com


HTML Include? [T4]

2007-05-30 Thread Josh Joy
Hi,
 
 I would like to include reusable HTML snippets which contain Tapestry code 
(jwcid) tags rather than build an actual component. There have been several 
posts that I searched through and the answer was to build a component, though 
I'm not sure if that will help in my case as I would like to keep the jwcid 
tags in place and NOT render them.
 
 Here is my situation, for example I have a sign up and edit info page. There 
is common Java code between the two and common HTML code as well. The Java code 
I can share by reusing the same base class. I would like to reuse the HTML 
code, such as below. Rather than copying and pasting, is there a way I can 
include common html code and componentize on that building one HTML page out of 
smaller common HTML pages? Thanks in advance.
 
 tr
 td align=right valign=top
 Username :
 /td
 td align=left
 table cellspacing=0 cellpadding=0 class=xxsmall_bold_arial 

   
 tr
 td align=left
 span jwcid=@If condition=ognl:userNameErr
 input type=text size=16 maxlength=16 jwcid=@TextField 
value=prop:userName class=backgroundinputfield_error /
 /span
 span jwcid=@Else 
 input type=text size=16 maxlength=16 jwcid=@TextField 
value=prop:userName /
 /span
 /td
 /tr
 tr
 td align=left valign=top
 span class=xxsmall_grey_arialno spaces please/span
 /td
 /tr
 /table
 /td
 /tr
 tr
 td align=right
  Password : 
 /td
 td align=left
 span jwcid=@If condition=ognl:passWordErr
 input type=password size=15 maxlength=15 jwcid=@TextField 
hidden=true value=prop:passWord class=backgroundinputfield_error/input
 /span
 span jwcid=@Else 
 input type=password size=15 maxlength=15 jwcid=@TextField 
hidden=true value=prop:passWord /
 /span
 /td
 /tr
 
 
 
 
 Thanks,
 Josh
 

an inner component want to get an outer component

2007-05-30 Thread Heping Zhang

hi, I have a login pane which embeded in a dojo dialog. And when login
successful, I want the dialog close. In my Login.java I wrote
   public void doLogin() {
   //...
   Dialog dlg = (Dialog)getComponent(loginDialog);
   dlg.hide();
   }

div jwcid=[EMAIL PROTECTED] hidden=ognl:loginHidden opacity=0.7
backgroundColor=#cfe1ed
   div jwcid=@Login /
/div

Component [EMAIL PROTECTED]/$Border.$Header.$Login] does not contain
a component loginDialog.
What can I do then? Or can I do something to tell the outer I am success and
you handle other thing? Thank you.


T5 Decoupling a Template From its Component Class

2007-05-30 Thread David Kendall
I am a Tapestry newbie getting up to speed on Tap 5. I am working on an
application with extensive co-branding requirements. 

As I understand things, there is - by default - a tight coupling between
a component class name and its template path. For example - if a
component has a FQCN of...

org.example.myapp.components.CClamp

...then the template has to be on the classpath as

org/example/myapp/components/CClamp.html

It would be very helpful if the mapping between the component and the
template could be decoupled - this would allow me to pull in component
templates that have been tweaked for a particular co-brand. 

For example - I might want to have a template on the class path as 

org/example/myapp/override/cobrand1/components/CClamp.html

Is there any way to do this?

Thanks in advance.

David Kendall




-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Re: T5 Decoupling a Template From its Component Class

2007-05-30 Thread Howard Lewis Ship

There are internal services that can be overridden to handle those kinds of
situations.

The goal is to create something that works amazingly well for all the more
typical cases, then start going after these others.  Often it will involve
moving a private interface out into the public space ... but once that's
done, its very hard to change the interface in the future without breaking
backwards compatibility, so we're pretty conservative about pulling back the
curtain until we know the interface is full and complete.

On 5/30/07, David Kendall [EMAIL PROTECTED] wrote:


I am a Tapestry newbie getting up to speed on Tap 5. I am working on an
application with extensive co-branding requirements.

As I understand things, there is - by default - a tight coupling between
a component class name and its template path. For example - if a
component has a FQCN of...

org.example.myapp.components.CClamp

...then the template has to be on the classpath as

org/example/myapp/components/CClamp.html

It would be very helpful if the mapping between the component and the
template could be decoupled - this would allow me to pull in component
templates that have been tweaked for a particular co-brand.

For example - I might want to have a template on the class path as

org/example/myapp/override/cobrand1/components/CClamp.html

Is there any way to do this?

Thanks in advance.

David Kendall




-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]





--
Howard M. Lewis Ship
TWD Consulting, Inc.
Independent J2EE / Open-Source Java Consultant
Creator and PMC Chair, Apache Tapestry
Creator, Apache HiveMind

Professional Tapestry training, mentoring, support
and project work.  http://howardlewisship.com


Re: A feature or a bug

2007-05-30 Thread Howard Lewis Ship

A feature!  On purpose, to remove redundancy from the URL.  The goal is to
allow you to select a longer class name but get a short URL.

On 5/30/07, petros [EMAIL PROTECTED] wrote:



I just noticed the following:

My tapestry page com.glintech.jumpstart.tapestry.users.UsersList is
translated in the following URL context/users/list instead of
context/users/userslist that I was expecting.

The Users is dropped from the name of the page. Is this done
itentionally
because the name of the page starts with the same substring as the name of
its package? I think I like this feature because it forces you to avoid
having information in your page name that is already captured by the name
of
the package.

However, is this a feature or a bug :)

Petros
--
View this message in context:
http://www.nabble.com/A-feature-or-a-bug-tf3844634.html#a10887703
Sent from the Tapestry - User mailing list archive at Nabble.com.


-
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]





--
Howard M. Lewis Ship
TWD Consulting, Inc.
Independent J2EE / Open-Source Java Consultant
Creator and PMC Chair, Apache Tapestry
Creator, Apache HiveMind

Professional Tapestry training, mentoring, support
and project work.  http://howardlewisship.com