interboy
interboy

Reputation: 886

Calling a method according to a timer set by the user

I am working on a JSF application that connects with Twitter. In one of my views, I have a button that when clicked, calls a method that connects with a Twitter account retrieving new tweets and doing some processing on them.

Next to the button I want to let the user to set a timer in order that this action is done automatically. For example if the user selects '2minutes', Twitter must be checked every 2 minutes automatically and the results be refreshed.

Can someone help with some general explanations how can I do this?

Upvotes: 0

Views: 826

Answers (1)

Daniel
Daniel

Reputation: 37071

Take a look at this Poll - Start/Stop

in your case

interval="#{myBean.someIntervalNum}" 

and so on...

Upvotes: 2

Related Questions