Pages usually don't have parameters. Components do!

g,
kris



Von:    m!g <gagau...@gmail.com>
An:     users@tapestry.apache.org
Datum:  07.02.2011 15:38
Betreff:        Tapestry 5 error "Caused by: java.lang.RuntimeException: 
Literal values are not updateable"




Hi everyone.
Here is a simple test application:

public class Test {
                 @Parameter(value="false")
                 @Property
                 private boolean test;

                 @Component
                 private Form form;

                 @Inject
                 private Request request;

                 Object onSubmitFromForm() {
                                 test=true;
                                 return null;
                 }
}

<html  xmlns:t="http://tapestry.apache.org/schema/tapestry_5_1_0.xsd";
xml:space="preserve">
<head></head>
<body>
<form t:id="form">
${test}
<t:submit/>
</form>
</body>
</html>


When I try to submit form I get error:


org.apache.tapestry5.runtime.ComponentEventException: Failure writing
parameter 'test' of component Test: Literal values
 are not updateable. [at classpath:ru/kupivip/pages/Test.tml, line 4]
                 at
org.apache.tapestry5.internal.structure.ComponentPageElementImpl.processEventTriggering(ComponentPageElementImpl.jav
a:1152)


Is it right behaviour of T5? Why I can't update parameter values?
-- 
View this message in context: 
http://tapestry.1045711.n5.nabble.com/Tapestry-5-error-Caused-by-java-lang-RuntimeException-Literal-values-are-not-updateable-tp3374330p3374330.html

Sent from the Tapestry - User mailing list archive at Nabble.com.

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org
For additional commands, e-mail: users-h...@tapestry.apache.org


Reply via email to