Eugene,
The refresh() is used by the portlet refresh an instance of an 
AbstractPortlet.  The purpose of refresh() is the allow the instance of 
the portlet to refresh it's content.

As an example: The WebPagePortlet uses refresh() to keep it's content 
current.  An instance of the WebPagePortlet is one URL.  The instance 
sets it's expiration based on the expiration of the page received from 
the server.  The cache system will call refresh() soon AFTER the 
expiration time has passed.  The instance will get a new page from the 
server, using the URL stored in the instance's configuration, and reset 
the expiration time using setExpirationMillis().  At no point is rundata 
involved.

Paul Spencer

Wang, Eugene wrote:

> I believe you can make any object a RefreshableCachedObject by implementing
> the Refreshable interface, thus implementing the refresh() function.  The
> TurbineGlobalCacheService will then checks the cache periodically(every 5
> seconds by default) and call clearCache().  clearCache() will call the
> refresh() method of the cached object if the cached object is a instance of
> RefreshableCachedObject.  I don't intend to cache the RunData object, but I
> can't figure out how to access it dynamically. 
> 
> -----Original Message-----
> From: Glenn Golden [mailto:[EMAIL PROTECTED]]
> Sent: Monday, May 13, 2002 5:54 PM
> To: 'Jetspeed Users List'
> Subject: RE: access to RunData in a portlet
> 
> 
> And how / when is your "refresh()" method going to be called?  Don't try to
> cache the rundata - it's good only for the duration of an http request.
> What do you mean by "refreshable"?
> 
> - Glenn
> 
> --------------------------------------------
> Glenn R. Golden, Systems Research Programmer 
> University of Michigan School of Information
> [EMAIL PROTECTED]               734-615-1419
> --------------------------------------------
> 
> 
> 
>>-----Original Message-----
>>From: Wang, Eugene [mailto:[EMAIL PROTECTED]] 
>>Sent: Monday, May 13, 2002 7:56 PM
>>To: 'Jetspeed Users List'
>>Subject: RE: access to RunData in a portlet
>>
>>
>>Thanks for responding Glenn  What I'm trying to do is to make 
>>my portlet refreshable, to do that I'm defining my own 
>>refresh() function.  To refresh my portlet, I'm just going to 
>>call getContent(RunData data) in the refresh() method.  But 
>>the problem is, in order to call getContent, I will need to 
>>pass it the RunData object.  Right now, I don't know how to 
>>get that. Thanks!
>>
>>eugene
>>
>>-----Original Message-----
>>From: Glenn Golden [mailto:[EMAIL PROTECTED]]
>>Sent: Monday, May 13, 2002 4:29 PM
>>To: 'Jetspeed Users List'
>>Subject: RE: access to RunData in a portlet
>>
>>
>>If you are doing an AbstractPortlet derived or other Java portlet, the
>>getContent() call is passed the rundata.
>>
>>If you are doing a VelocityPortlet, the $data is available in 
>>the context for the .vm file.
>>
>>- Glenn
>>
>>--------------------------------------------
>>Glenn R. Golden, Systems Research Programmer 
>>University of Michigan School of Information
>>[EMAIL PROTECTED]               734-615-1419
>>--------------------------------------------
>>
>>
>>
>>>-----Original Message-----
>>>From: Wang, Eugene [mailto:[EMAIL PROTECTED]]
>>>Sent: Monday, May 13, 2002 6:29 PM
>>>To: '[EMAIL PROTECTED]'
>>>Subject: access to RunData in a portlet
>>>
>>>
>>>Hi there,
>>>     Does anyone know how to get access to the RunData
>>>object in a portlet?  There used to be a function called 
>>>getRunData in the PortletConfig class, so to get the RunData 
>>>object in a portlet,  simply call 
>>>getPortletConfig().getRunData().  However, this method has 
>>>been removed in 1.3a2 release.  Does anyone know why?  How do 
>>>I get the RunData object now?
>>>Please help!   Thanks much!
>>>
>>>eugene
>>>
>>>Eugene Wang
>>>Corio Technologies
>>>650-232-3045
>>>[EMAIL PROTECTED]
>>>
>>>Building a successful enterprise requires three men - a
>>>dreamer, a business man and a son of a bitch
>>>  
>>>-- Peter McArthur
>>>
>>>
>>>
>>>
>>>--
>>>To unsubscribe, e-mail:   
>>><mailto:jetspeed-user-> [EMAIL PROTECTED]>
>>>For
>>>additional commands, 
>>>e-mail: <mailto:[EMAIL PROTECTED]>
>>>
>>--
>>To unsubscribe, e-mail:
>><mailto:[EMAIL PROTECTED]>
>>For additional commands, e-mail:
>><mailto:[EMAIL PROTECTED]>
>>
>>--
>>To unsubscribe, e-mail:   
>><mailto:jetspeed-user-> [EMAIL PROTECTED]>
>>For 
>>additional commands, 
>>e-mail: <mailto:[EMAIL PROTECTED]>
>>
> 
> --
> To unsubscribe, e-mail:
> <mailto:[EMAIL PROTECTED]>
> For additional commands, e-mail:
> <mailto:[EMAIL PROTECTED]>
> 
> --
> To unsubscribe, e-mail:   <mailto:[EMAIL PROTECTED]>
> For additional commands, e-mail: <mailto:[EMAIL PROTECTED]>
> 
> 



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

Reply via email to