Code example for Formatter

Methods: closeformat

	 * @param time the time to format, in milliseconds 
	 * @return a string containing the formatted time 
	protected static String formatTime(long time) {
		StringBuffer output = new StringBuffer();
		Formatter formatter = new Formatter(output);
		formatter.format("%tY-%tm-%td %tT", time, time, time, time);
		return output.toString();
	protected void requestNow() { 
		new WotdTask(this).execute();
	protected void startRerequesting() { 
		// begin rechecking every 15 minutes 
		Intent serviceIntent = new Intent(getApplicationContext(), DubsarService.class);
		PendingIntent pendingIntent = PendingIntent.getService(this, 0, serviceIntent, 0);
Connect your IDE to all the code out there  Get Codota for Java