I am using swing based model.My form contains one Jbutton its called "polling(function name is getvalue())".I have a function name as "getvalue()".This function does retrieve values(this value will change after some span of time) and print it in console. I want code and idea about, that function will call automatically every 5 minutes ( or some span of time interval)and retrieve values and print it in console.I want code using timer concept .
my button function is like
private void ActionPerformed(java.awt.event.ActionEvent evt) {
}
where will write my Automatic polling code.