Re: [T5.2.6] When can a java.net.URL be returned from an event handler?

2012-10-25 Thread wout86
anyone? -- View this message in context: http://tapestry.1045711.n5.nabble.com/T5-2-6-When-can-a-java-net-URL-be-returned-from-an-event-handler-tp5716618p5717221.html Sent from the Tapestry - User mailing list archive at Nabble.com. -

Re: [T5.2.6] When can a java.net.URL be returned from an event handler?

2012-10-22 Thread wout86
Ok, I'll add some more context here. The event handling code I'm talking about is actually invoked in a component's /dispatchComponentEvent/ function. It is added as 'before' advice on this function through a Tapestry Class Transformation. Basically, the event handling code verifies a boolean an

Re: [T5.2.6] When can a java.net.URL be returned from an event handler?

2012-10-16 Thread wout86
Any other ideas? -- View this message in context: http://tapestry.1045711.n5.nabble.com/T5-2-6-When-can-a-java-net-URL-be-returned-from-an-event-handler-tp5716618p5716986.html Sent from the Tapestry - User mailing list archive at Nabble.com.

Re: [T5.2.6] When can a java.net.URL be returned from an event handler?

2012-10-04 Thread wout86
It should be... No other piece of event handler code returns URLs. -- View this message in context: http://tapestry.1045711.n5.nabble.com/T5-2-6-When-can-a-java-net-URL-be-returned-from-an-event-handler-tp5716618p5716638.html Sent from the Tapestry - User mailing list archive at Nabble.com. --

Re: [T5.2.6] When can a java.net.URL be returned from an event handler?

2012-10-04 Thread wout86
That's possible; I do however perform the test to make sure the URL is only returned when !request.isXHR() (where request is an instance of org.apache.tapestry5.services.Request). Is there any other check that I should perform? -- View this message in context: http://tapestry.1045711.n5.nabble.

Re: [T5.2.6] When can a java.net.URL be returned from an event handler?

2012-10-04 Thread wout86
Hi Lance, Thanks for the quick reply. 2) nope 3) I think not; my code which returns URLs typically works, but only sometimes I get the error that a returned URL cannot be handled. 1) Can you clarify this? I don't really understand this question... -- View this message in context: http://tape

Re: Tapestry Spring Security for 5.4-SNAPSHOT

2012-07-27 Thread wout86
Hi Daniel, Do you allow others to commit to your fork as well? Otherwise, I'd be interested as I still have an improvement on the latest tapestry-spring-security which is apparently not yet present in the fork. Best Regards, Wouter -- View this message in context: http://tapestry.1045711.n5.n

Re: Is it possible to obtain page instances programmatically by name?

2012-07-26 Thread wout86
Thanks Bryan, that's actually what I was looking for! -- View this message in context: http://tapestry.1045711.n5.nabble.com/Is-it-possible-to-obtain-page-instances-programmatically-by-name-tp5714794p5714824.html Sent from the Tapestry - User mailing list archive at Nabble.com. ---

Is it possible to obtain page instances programmatically by name?

2012-07-26 Thread wout86
Hi, We all know Tapestry page instances can be obtained by "injecting" them in a variable using its type or its name, e.g., as follows: @InjectPage private HomePage home; or @InjectPage("HomePage") private Object home; However, this method only allows pages to be injected whose names are known

RE: [T5.2.6] AjaxFormLoop containing tr's rather than being a tr

2012-05-30 Thread wout86
Pieter, Thanks for the reply, I forgot to mention that in first instance, the table renders correctly, but it goes all wrong when using the add row link. Could you try that? In my case, the new "rows" are shown out of the table (above it to be specific). -- View this message in context: http://

[T5.2.6] AjaxFormLoop containing tr's rather than being a tr

2012-05-30 Thread wout86
Hi, I'm wondering whether it is possible to have an AjaxFormLoop containing multiple tr elements? For instance, this works: H1... <*tr *t:type="AjaxFormLoop" t:source="src" t:value="el" t:encoder="elEncoder" t:show="show"> E1 ... ... ... ... tr*> But I'd

Re: Is it possible to add Field validators at render-time?

2012-05-06 Thread wout86
Lance, the 'prepare' event might be fired, but apparently it's not dealt with by a page component. -- View this message in context: http://tapestry.1045711.n5.nabble.com/Is-it-possible-to-add-Field-validators-at-render-time-tp5682920p5690332.html Sent from the Tapestry - User mailing list archiv

Re: Is it possible to add Field validators at render-time?

2012-05-04 Thread wout86
>I disagree. Tapestry would need to persist the validators somehow. Ok, if it isn't persisting the TextField already, I agree with you. But I thought it did that somehow. -- View this message in context: http://tapestry.1045711.n5.nabble.com/Is-it-possible-to-add-Field-validators-at-render-time

Re: Is it possible to add Field validators at render-time?

2012-05-04 Thread wout86
PS: If I recall correctly, a component can only be implemented in terms of render event handlers, and the activate event isn't a render event (http://tapestry.apache.org/component-rendering.html). Either way, I tried to add an onActivate() method to be sure, and it didn't get invoked. -- View this

Re: Is it possible to add Field validators at render-time?

2012-05-04 Thread wout86
I know, it's only called during (before) rendering. Anyway, after inspecting the stack trace, I found out that Tapestry is re-evaluating the /validate/ parameter of a TextField upon form submission. More specifically, when the form is submitted, the TextField is asked to validate itself and to thi

Re: Is it possible to add Field validators at render-time?

2012-05-04 Thread wout86
Full error output: ERROR org.apache.tapestry5.ioc.Registry - Failure reading parameter 'validate' of component MyPage:fieldID: Component MyPage does not contain a stored render variable with name 'validators'. Stored render variables: (none). ERROR org.apache.tapestry5.ioc.Registry - Operations t

Re: Is it possible to add Field validators at render-time?

2012-05-04 Thread wout86
Yup, I avoided that code because I'd like the customcomponent to be flexible, not requiring a specific type of Field in its body, or a specific name for that Field. In the meanwhile, I've been able to get the field reference in the custom component as follows: This works , but: apparently t

Re: Is it possible to add Field validators at render-time?

2012-05-03 Thread wout86
Hi, Well, passing a parameter to the field to configure its validator is exactly what I'm trying to do. The fields I need already take a parameter for this purpose (i.e., t:validate), so it doesn't seem useful to extend them to use Environmentals instead. The issue here is that t:validate works w

Re: Is it possible to add Field validators at render-time?

2012-05-03 Thread wout86
Thiago, I want to apply the same logic that's applied when using a Page property in a tml to output text: I want to use a component's property (render variable in this case) in its body to set the validator for a field in this body. That doesn't seem too wrong to me, does it? -- View this message

Re: Is it possible to add Field validators at render-time?

2012-05-03 Thread wout86
Lance, I'm currently unable to access my workstation, but I invoked the /resources.getComponentModel().getEmbeddedComponentIds();/ in both setupRender() and cleanupRender() earlier today. Both invocations returned an empty list. -- View this message in context: http://tapestry.1045711.n5.nabble.

Re: Is it possible to add Field validators at render-time?

2012-05-03 Thread wout86
Yup I know about the page render variables, but that works. The problem is getting access to the embedded field.. (i.e., the TextField, or any field with a specific name, in the body of the custom component) The custom component itself doesn't have a tml file, it just employs the render phase event

Re: Is it possible to add Field validators at render-time?

2012-05-03 Thread wout86
Thanks, that'll work indeed. Do you happen to know whether it's also possible to inject such a field from the body of a custom component in that custom component? For instance, let's say we have: Where I'd like to access the tf1 textfield in mycomponent's java class to create the validator

Re: Is it possible to add Field validators at render-time?

2012-05-03 Thread wout86
No go :/. org.apache.tapestry5.ioc.Registry - Exception assembling root component of page MyPage: Could not convert 'prop:validate:validators' into a component parameter binding: Error parsing property expression 'validate:validators': Unable to parse input at character position 9. -- View this

Re: Is it possible to add Field validators at render-time?

2012-05-03 Thread wout86
That'd be a great solution, but it doesn't seem to work :-(. Caused by: org.apache.tapestry5.ioc.internal.util.TapestryException: Failure reading parameter 'validate' of component MyPage:name: Unexpected character ':' at position 5 of input string: prop:validators. -- View this message in conte

Is it possible to add Field validators at render-time?

2012-05-03 Thread wout86
Hi, I was wondering whether it is possible to add Validators to a Tapestry field (e.g., TextField) at render-time (based on a runtime property)? More specifically, I'd like to know whether I can avoid doing: and change it by something like with public String getAndRequired {

Re: Reading out a Component's formal parameters' values

2012-05-03 Thread wout86
Thanks for the tip! Having read the documentation on Environmentals, it looks to me like I have to push the required values in the outer component in a method that will lead to the invocation of the validator method where I need them, and pop the values, for instance, when this method returns. I

Re: Reading out a Component's formal parameters' values

2012-05-02 Thread wout86
Actually, the validator will be applied to a component that's one level deeper than my custom component (for instance: ; where customvalidator requires the values of a and b). -- View this message in context: http://tapestry.1045711.n5.nabble.com/Reading-out-a-Component-s-formal-parameters-values

Re: Reading out a Component's formal parameters' values

2012-05-02 Thread wout86
Actually, the validator will be applied to a component that's one level deeper than my custom component (for instance: ; where customvalidator requires the values of a and b). -- View this message in context: http://tapestry.1045711.n5.nabble.com/Reading-out-a-Component-s-formal-parameters-values

Reading out a Component's formal parameters' values

2012-05-02 Thread wout86
Hi, I was wondering whether it's possible to read out a *Component*'s formal parameters' values? Up till now, I was only able to find the /getInformalParameter(String name, Class type)/ function in *ComponentResources*, which only allows to read out informal parameters. Some Context: I'd like to