Android Hour Format formatHour(int val)

Here you can find the source of formatHour(int val)

Description

format Hour

Declaration

public static String formatHour(int val) 

Method Source Code

//package com.java2s;

public class Main {
    public static String formatHour(String string) {
        return (string.length() == 1) ? "0" + string : string;
    }/*from www  . j  a  va2  s  .  c o m*/

    public static String formatHour(int val) {
        return formatHour(String.valueOf(val));
    }
}

Related

  1. formatHour(String string)
  2. getReminderReadableTime(int hour, int minute)
  3. getCurrentHour()
  4. getDateByAddHour(String datetime, int minute)
  5. getDateByAddFltHour(float flt)