Android Year Offset Get getYear_Second1()

Here you can find the source of getYear_Second1()

Description

get Yea Second

Declaration

public static String getYear_Second1() 

Method Source Code

//package com.java2s;
import java.sql.Timestamp;

import java.text.SimpleDateFormat;

public class Main {

    public static String getYear_Second1() {

        Timestamp stamp1 = new Timestamp(System.currentTimeMillis());
        SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");
        String timeStr = sdf.format(stamp1);
        return timeStr;
    }/* w w w  .j  a v  a  2 s.  c  om*/
}

Related

  1. yearOffset(Date date, int offset)
  2. getOneYearAgo()
  3. yearDays(int y)
  4. getYearMonthDay1()
  5. getYearMonthDay2()
  6. getYear_Second2()