Re: Creating Grid component at runtime

2010-09-26 Thread kamath_svk

As advised in the previous reply, i can create a class which contains all the
column  display only those column names which are present in the query.
But i think that will be waste of memory since, I have 50 column names from
col1,col2,.. col50.
Consider the situation where only one column is select by query, the object
created will use the storage for all 50 columns where as only 1 is actually
useful.

so i wanted to know, if i can use beanmodel to add the columns dynamically
at runtime.
-- 
View this message in context: 
http://tapestry.1045711.n5.nabble.com/Creating-Grid-component-at-runtime-tp2847820p2854386.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



Re: Redirect when session is destroyed

2010-09-26 Thread kamath_svk


Thiago H. de Paula Figueiredo wrote:
 
 If inside a page, check the page navigation page in the documentation.
 

I was not referring to redirecting from page.
As we know if session is expired sessionDestroyed method is called by
tapestry.
(Please refer the code)
http://eubauer.de/kingsware/2010/02/04/track-login-and-logout-of-users-with-tapestry-5/
 

I was referring to a scenario wherein if session is expired user is
automatically redirected to start or index page. So i was asking, how to
redirect to start page from sessionDestroyed method.

Thank you for the links provided, that would be really helpful to me.
-- 
View this message in context: 
http://tapestry.1045711.n5.nabble.com/how-to-Redirect-in-sessionDestroyed-method-tp2849255p2854394.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



RE: Creating Grid component at runtime

2010-09-26 Thread Jim O'Callaghan
Can you use a helper class that contains getters for all the possible fields
you require, and them dynamically build a comman delimited include (or
exclude) string, that you pass to your grid using include/exclude via a
page property?

Regards,
Jim.

-Original Message-
From: kamath_svk [mailto:kamath...@yahoo.co.in] 
Sent: 26 September 2010 15:40
To: users@tapestry.apache.org
Subject: Re: Creating Grid component at runtime


As advised in the previous reply, i can create a class which contains all
the
column  display only those column names which are present in the query.
But i think that will be waste of memory since, I have 50 column names from
col1,col2,.. col50.
Consider the situation where only one column is select by query, the object
created will use the storage for all 50 columns where as only 1 is actually
useful.

so i wanted to know, if i can use beanmodel to add the columns dynamically
at runtime.
-- 
View this message in context:
http://tapestry.1045711.n5.nabble.com/Creating-Grid-component-at-runtime-tp2
847820p2854386.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



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



RE: Creating Grid component at runtime

2010-09-26 Thread Jim O'Callaghan
Re-reading your email Kamath I can see you have already been advised on this
approach.  Perhaps if the non-primitive properties used for the display
class were only initialised to a value by their setters the memory issue
would be not relevant, and you would already have the names of the
properties for the include/exclude parameter of the grid by taking them from
the query.

Regards,
Jim.

-Original Message-
From: Jim O'Callaghan [mailto:jc1000...@yahoo.co.uk] 
Sent: 26 September 2010 15:55
To: 'Tapestry users'
Subject: RE: Creating Grid component at runtime

Can you use a helper class that contains getters for all the possible fields
you require, and them dynamically build a comman delimited include (or
exclude) string, that you pass to your grid using include/exclude via a
page property?

Regards,
Jim.

-Original Message-
From: kamath_svk [mailto:kamath...@yahoo.co.in] 
Sent: 26 September 2010 15:40
To: users@tapestry.apache.org
Subject: Re: Creating Grid component at runtime


As advised in the previous reply, i can create a class which contains all
the
column  display only those column names which are present in the query.
But i think that will be waste of memory since, I have 50 column names from
col1,col2,.. col50.
Consider the situation where only one column is select by query, the object
created will use the storage for all 50 columns where as only 1 is actually
useful.

so i wanted to know, if i can use beanmodel to add the columns dynamically
at runtime.
-- 
View this message in context:
http://tapestry.1045711.n5.nabble.com/Creating-Grid-component-at-runtime-tp2
847820p2854386.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



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



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



Re: Redirect when session is destroyed

2010-09-26 Thread Thiago H. de Paula Figueiredo
On Sun, 26 Sep 2010 11:53:44 -0300, kamath_svk kamath...@yahoo.co.in  
wrote:



As we know if session is expired sessionDestroyed method is called by
tapestry.


This method is not called by Tapestry, but by the servlet container  
(server).



(Please refer the code)
http://eubauer.de/kingsware/2010/02/04/track-login-and-logout-of-users-with-tapestry-5/

I was referring to a scenario wherein if session is expired user is
automatically redirected to start or index page.


It's only possible to redirect when a request is made.


So i was asking, how to
redirect to start page from sessionDestroyed method.


It's not possible. Instead, create a RequestFilter that checks if the  
session exists and the user is logged in, then use Redirect.sendRequest()  
if needed. This is similar to the approach in the URL you provided.


--
Thiago H. de Paula Figueiredo
Independent Java, Apache Tapestry 5 and Hibernate consultant, developer,  
and instructor

Owner, Ars Machina Tecnologia da Informação Ltda.
http://www.arsmachina.com.br

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