function DateUtil(){

	this.getUTCNow = function(){
	
		var now = new Date();
		
		return now.getUTCFullYear() + "-" + this.sprintf(now.getUTCMonth()+1) + "-" + this.sprintf(now.getUTCDate()) +
		" " +
		this.sprintf(now.getUTCHours()) +
		":" +
		this.sprintf(now.getUTCMinutes()) +
		":" +
		this.sprintf(now.getUTCSeconds());
	}
	
	// Returns hours and minutes
	this.getTime = function(_utcTime, _showSeconds){
	
		var _utcHour = _utcTime.substring(11, 13);
		var _utcMinute = _utcTime.substring(14, 16);
		var _utcSecond = _utcTime.substring(17, 19);
	
		var date = new Date();
		date.setUTCHours(_utcHour);
		date.setUTCMinutes(_utcMinute);
		date.setUTCSeconds(_utcSecond);
		
		var time = this.sprintf(date.getHours()) + ":" + this.sprintf(date.getMinutes());
		
		if (_showSeconds == true) 
			time += ":" + date.getSeconds();
		
		return time;
	}
	
	this.sprintf = function(_value) {
		
		if(_value < 10)
			return "0" + _value;
			
		return _value;
	}
}
