tapestry-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Apache Wiki <wikidi...@apache.org>
Subject [Tapestry Wiki] Update of "Tapestry5HibernateGridDatasource" by LorenzoSimionato
Date Sat, 12 Jun 2010 09:52:36 GMT
Dear Wiki user,

You have subscribed to a wiki page or wiki category on "Tapestry Wiki" for change notification.

The "Tapestry5HibernateGridDatasource" page has been changed by LorenzoSimionato.
http://wiki.apache.org/tapestry/Tapestry5HibernateGridDatasource?action=diff&rev1=1&rev2=2

--------------------------------------------------

  = Using HibernateGridDatasource =
  
+ One of the easiest way to use the [[http://tapestry.apache.org/tapestry5.1/tapestry-core/ref/org/apache/tapestry5/corelib/components/Grid.html|
Grid Component]] with Hiberante, is to use the [[http://tapestry.apache.org/tapestry5/apidocs/org/apache/tapestry5/hibernate/HibernateGridDataSource.html|HibernateGridDatasource]]
class, from the tapestry-hibernate module.
+ 
+ Consider this snippets of a page:
+ 
+ {{{
+ <t:grid t:source="list"/>
+ }}}
+ 
+ The Java class associated to the page is simply:
+ 
+ {{{
+     import org.apache.tapestry5.hibernate.HibernateGridDataSource;
+     ...
+     @Inject
+     private Session session;
+ 
+     public GridDataSource getList() {
+         return new HibernateGridDataSource(session, Entity.class);
+     }
+ }}}
+ 

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@tapestry.apache.org
For additional commands, e-mail: dev-help@tapestry.apache.org


Mime
View raw message