Java Hour Format formatTime_(String time)

Here you can find the source of formatTime_(String time)

Description

format Tim_

License

Apache License

Declaration

public static Date formatTime_(String time) throws ParseException 

Method Source Code


//package com.java2s;
// Licensed under the Apache License, Version 2.0 (the "License");

import java.text.DateFormat;
import java.text.ParseException;
import java.text.SimpleDateFormat;

import java.util.Date;

public class Main {
    public static Date formatTime_(String time) throws ParseException {
        time = time.replaceAll("T", " ");
        DateFormat format = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss+0000");
        return format.parse(time);
    }// w w  w  .  j a v a  2s  .c o m
}

Related

  1. formatTime(long time)
  2. formatTime(long time)
  3. formatTime(long time)
  4. formatTime(long time, TimeUnit unit)
  5. formatTime(String dateTimeString)
  6. formatTime_1(long time_value)
  7. formatTime_2(long time_value, long frame_rate)
  8. formatToHour(Date date)
  9. formatToOpenMrsDate(Date date)