Java Date Now getCurrentDate()

Here you can find the source of getCurrentDate()

Description

get Current Date

License

Apache License

Declaration

public static String getCurrentDate() 

Method Source Code


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

import java.text.SimpleDateFormat;

public class Main {
    public static String getCurrentDate() {
        String currentDate = "";
        SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd");
        currentDate = sdf.format(new java.util.Date());
        return currentDate;
    }/*from ww  w .  j a va 2  s  .c o  m*/
}

Related

  1. getCurrentDate()
  2. getCurrentDate()
  3. getCurrentDate()
  4. GetCurrentDate()
  5. getCurrentDate()
  6. getCurrentDate()
  7. getCurrentDate(boolean WithDelimeter)
  8. getCurrentDate(Date date)
  9. getCurrentDate(final String form)