Code example for GregorianCalendar

Methods: get, setTime

0
		return builder.toString();
	} 
	 
	public static int getDayOfWeek(Date d)
	{ 
		Calendar cal = new GregorianCalendar();
		cal.setTime(d);
		return cal.get(Calendar.DAY_OF_WEEK);
	} 
	 
	public static void pingOut(String url)
	{ 
		if (url==null || url=="") return;
		try { 
			if (url.contains("[outsideTemp]")) url = url.replace("[outsideTemp]", String.valueOf(Conditions.getCurrent().getOutsideTemperature()) );
			if (url.contains("[insideTemp]")) url = url.replace("[insideTemp]", String.valueOf(Conditions.getCurrent().getInsideTemperature()) );
 
			Utils.logInfo("Pinging - " + url, "data.Utils.pingOut");
			Utils.getUrlContents(url);
		} catch (Exception e) {
			Utils.logError(e.toString(), "data.Utils.pingOut");