var Timer=Class.create({
	initialize: function(){
		this.limit=arguments[0].limit;
		this.action=typeof(arguments[0].action)=='undefined'?function(){}:arguments[0].action;
		this.timer=null;
	},
	setAction:function()
	{
		this.action=arguments[0];
	},
	start:function(){
		if(this.timer)this.stop();
		this.timer=setTimeout(this.action,this.limit*1000);
		//document.title="started";
	},
	stop:function(){
		clearTimeout(this.timer);
		//document.title="stopped";	
	},
	excute:function()
	{
		this.action();
	}
});
