RE: T5: Loop with @Component does not work

2007-04-13 Thread Kristian Marinkovic
hi all,

sorry for my previous post of course it works!!

my failure was that i had the Loop as public property 
without a getter method... if you do so you get an Error
message in your log you should read :)

g,
kris




Kristian Marinkovic [EMAIL PROTECTED] 
13.04.2007 12:09
Bitte antworten an
Tapestry users [EMAIL PROTECTED]


An
Tapestry users [EMAIL PROTECTED]
Kopie

Thema
T5: Loop with @Component does not work






hi, 

could someone help me to apply a T5 Loop with the
@Component annotation? The following code does 
not work all the necessary getter/setter methods are
in place (modification of T5 tutorial).

... or maybe the Loop is not meant to be used this way :)

g,
kris

span t:id=looping
a t:type=actionlink context=index${index}/a
/span

@Component(parameters={source=range,value=index})
public Loop looping;
 
private static ListString range = new ArrayListString();
static {
   range.add(1);
   range.add(2);
   range.add(3);
}


Re: T5: Loop with @Component does not work

2007-04-13 Thread Robert Zeigler
Right.  Annotations on properties will only be processed if the  
properties are private.
In fact, for components, unless you're going to access the component  
externally, you don't need a getter.




On Apr 13, 2007, at 4/135:50 AM , Kristian Marinkovic wrote:


hi all,

sorry for my previous post of course it works!!

my failure was that i had the Loop as public property
without a getter method... if you do so you get an Error
message in your log you should read :)

g,
kris




Kristian Marinkovic [EMAIL PROTECTED]
13.04.2007 12:09
Bitte antworten an
Tapestry users [EMAIL PROTECTED]


An
Tapestry users [EMAIL PROTECTED]
Kopie

Thema
T5: Loop with @Component does not work






hi,

could someone help me to apply a T5 Loop with the
@Component annotation? The following code does
not work all the necessary getter/setter methods are
in place (modification of T5 tutorial).

... or maybe the Loop is not meant to be used this way :)

g,
kris

span t:id=looping
a t:type=actionlink context=index${index}/a
/span

@Component(parameters={source=range,value=index})
public Loop looping;

private static ListString range = new ArrayListString();
static {
   range.add(1);
   range.add(2);
   range.add(3);
}



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



Re: T5: Loop with @Component does not work

2007-04-13 Thread Howard Lewis Ship

I often have to add @SuppressWarnings(unused) to the field which
defines the component as well.

On 4/13/07, Robert Zeigler [EMAIL PROTECTED] wrote:

Right.  Annotations on properties will only be processed if the
properties are private.
In fact, for components, unless you're going to access the component
externally, you don't need a getter.



On Apr 13, 2007, at 4/135:50 AM , Kristian Marinkovic wrote:

 hi all,

 sorry for my previous post of course it works!!

 my failure was that i had the Loop as public property
 without a getter method... if you do so you get an Error
 message in your log you should read :)

 g,
 kris




 Kristian Marinkovic [EMAIL PROTECTED]
 13.04.2007 12:09
 Bitte antworten an
 Tapestry users [EMAIL PROTECTED]


 An
 Tapestry users [EMAIL PROTECTED]
 Kopie

 Thema
 T5: Loop with @Component does not work






 hi,

 could someone help me to apply a T5 Loop with the
 @Component annotation? The following code does
 not work all the necessary getter/setter methods are
 in place (modification of T5 tutorial).

 ... or maybe the Loop is not meant to be used this way :)

 g,
 kris

 span t:id=looping
 a t:type=actionlink context=index${index}/a
 /span

 @Component(parameters={source=range,value=index})
 public Loop looping;

 private static ListString range = new ArrayListString();
 static {
range.add(1);
range.add(2);
range.add(3);
 }


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