var Timer = new Class(
{
	period: 5000,
	timerAuto: undefined,
	callback: [],
	
	initialize: function (period)
	{
		if (period != undefined) this.period = period;
		this.timerAuto = this.tick.periodical(this.period, this);
	},
	
	register: function (callback)
	{
		this.callback.push(callback);
	},
	
	tick: function ()
	{
		this.callback.each(function (el)
		{
			if (typeof(el) === 'function') el();
		});
	}
});

