Java Now getTimeNow()

Here you can find the source of getTimeNow()

Description

get Time Now

License

Open Source License

Declaration

public static String getTimeNow() 

Method Source Code

//package com.java2s;
//License from project: Open Source License 

import java.text.SimpleDateFormat;

import java.util.Calendar;

public class Main {
    public static String getTimeNow() {
        Calendar cal = Calendar.getInstance();
        cal.getTime();/* w  w  w.  ja v  a 2s  . c  om*/
        SimpleDateFormat sdf = new SimpleDateFormat("HH:mm:ss");
        return sdf.format(cal.getTime());
    }
}

Related

  1. getFormattedDateNow(@Nonnull final String sFormat)
  2. getInviteCodeByNowDate()
  3. getShortNowTime()
  4. getStringNowTime()
  5. getStringOfNowDate(String fFormatStr)
  6. getTimeNow(Date theTime)
  7. getTimeNowAsString(String pattern)
  8. getTimeSubFromNowTime(String time)
  9. getValidDate(String unknownDate)