Java Time Now currtimeToString8()

Here you can find the source of currtimeToString8()

Description

currtime To String

License

LGPL

Declaration

public static String currtimeToString8() 

Method Source Code

//package com.java2s;
//License from project: LGPL 

import java.text.SimpleDateFormat;

import java.util.Date;

public class Main {

    public static String currtimeToString8() {
        return dateToString(new Date(), "yyyyMMdd");
    }//from   www .  j  a va2  s. c om

    public static String dateToString(Date date, String format) {
        SimpleDateFormat sf = new SimpleDateFormat(format);
        return sf.format(date);
    }
}

Related

  1. currentTimeMillis()
  2. currentTimePath(String basePath)
  3. currentTimeStr()
  4. currentTimeString()
  5. currentTimeString(String pattern)
  6. get_cur_datetime()
  7. getCurDateBefore(long time)
  8. getCurDateTime()
  9. getCurDateTIme()