Java Time Format getTime(Date time, int format, Locale locale)

Here you can find the source of getTime(Date time, int format, Locale locale)

Description

get Time

License

Open Source License

Declaration

public static String getTime(Date time, int format, Locale locale) 

Method Source Code

//package com.java2s;
/*******************************************************************************
 * All rights reserved. This program and the accompanying materials
 * are made available under the terms of the Eclipse Public License v1.0
 * which accompanies this distribution, and is available at
 * http://www.eclipse.org/legal/epl-v10.html
 *******************************************************************************/

import java.text.SimpleDateFormat;
import java.util.Date;
import java.util.Locale;

public class Main {
    public static String getTime(Date time, int format, Locale locale) {
        return SimpleDateFormat.getTimeInstance(format, locale).format(time);
    }//from w w  w.jav a2s  .  c o m
}

Related

  1. getStringFromTime(Date time, String format)
  2. getSysDateTimeForFileName()
  3. getSysTimeYMDHMS2()
  4. getTime(@Nonnull String format, @Nonnull String date, @Nonnull String tz)
  5. getTime(Date dt, String format)
  6. getTime(DateFormat df)
  7. getTime(int format)
  8. getTime(long time, int timeFormat)
  9. getTime(String dateStr, String format)