On Tue, 28 May 2013 20:33:33 -0300, Ken in Nashua <kcola...@live.com>
wrote:
Hi Folks,
Hi!
I have a page that renders a collection in a grid.
A hibernate collection...
@Persist
@Property
private Collection collection;
@SetupRender
public void setupRender() {
beanType = PlayerStats.class;
collection = playerStats = new ArrayList(
TynamoUTIL.loadCollectionByYearAndLeagueAndSeason(
hibernatePersistenceService,
year, league, season, PlayerStats.class));
// I know its hoakey for now
grid.reset();
}
I see no reason for @Persist'ing a filed that is set in a setupRender()
method.
but my getSource is giving me an NPE
public GridDataSource getSource() {
return new CollectionGridDataSource(collection);
}
Weird. Could you post the full stack trace? Have you checked whether your
setupRender() method is really being called? If the page with these fields
and methods isn't the one being requested, the setupRender() method won't
be called. In addition, if the only place you use the collection field is
in getSource(), you could get the collection from inside getSource()
directly, without using setupRender() for that.
I thought my properties would be binded by now
These other fields are completely unrelated to your problem.
--
Thiago H. de Paula Figueiredo
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@tapestry.apache.org
For additional commands, e-mail: users-h...@tapestry.apache.org