With all distractions I have right now I haven't had a lot of time to
finish my table, but I got back to it and followed advise from you guys and
a similar example to my own which seems very straight forward.

I'm following the 'Grid row highlighter
demo<http://lombok.demon.co.uk/tapestry5Demo/test/mixins/gridrowhighlighterdemo>'
by  Shing Hing Man to construct my table with a few ommissions (don't need
cell highlighting for example),  however,  on creating my beanmodel (which
has only getMethods and setMethods and the respective instance members when
I try to execute/run my project I get the following exceptions:

java.lang.RuntimeException
Exception assembling root component of page LeaderboardPage: Unable to
instantiate instance of transformed class
com.sony.otg.c3demoapp.pages.DoStuffPage:
java.lang.reflect.InvocationTargetException

which is caused by:

java.lang.reflect.InvocationTargetExceptiontargetExceptionorg.apache.tapestry5.ioc.internal.OperationException:
Unable to create new accessor method public int getPosition() on class
com.sony.otg.c3demoapp.pages.DoStuff as the method is already implemented.
I read somewhere that Tapestry will create get/set methods that are not
present but since I have provided them why do I get this error?  Commenting
them out is not an option because in my class Decode (which parses my Json
input) I call setMethodName (and getMethodName) for each of the items I
retrieve from the Json object.  I would also have to omit the getMethods as
well and this would leave my beanmodel pretty empty and I don't see what
I'm doing wrong.

If I compare this example with the 'Grid' example on jumpstart then I see
that the @Entity annotation is being used along with 'implements
Serializeable'.  The 'Grid row demo' doesn't use either of these and so I'm
a bit confused as to which is the 'correct' way to go.

So my questions are:

1 - Why does Tapestry complain if I implement getMethodName/setMethodName ?
2 - Should I Serialize my class and annotate it with @Entity?
3 - Both of the two examples create a table/grid when the page loads
using pageLoaded()
or setupRender() calls, but I only want a table generated onClick from a
link I have on the page.  Is it good practice to do this using an Event
Link that will then render my table on the same page?

Again, thanks for any responses/support from the Tapestry Users.

Regards

Az


On Thu, Apr 26, 2012 at 11:52 AM, Az Madu <azm...@gmail.com> wrote:

> Thanks Lance/Thiago for your suggestions, I'm looking into doing that now.
>
> Regards
>
> Az
>
>
> On Thu, Apr 26, 2012 at 11:26 AM, Lance Java <lance.j...@googlemail.com>wrote:
>
>> If I understand correctly, you read your data into multiple lists. To read
>> a single record, you use the same index in each list... Correct?
>>
>> This sort of model often leads to a maintenance nightmare.
>>
>> Create a bean which represents a single row in the grid and read your data
>> into a single list.  You'll thank me in the future ;)
>>
>
>

Reply via email to