Android File Name Create createImageName()

Here you can find the source of createImageName()


create Image Name


    public static String createImageName() 

Method Source Code

//package com.java2s;
import java.text.SimpleDateFormat;
import java.util.Date;
import android.annotation.SuppressLint;

public class Main {
    public static String createImageName() {
        SimpleDateFormat dateFormat = new SimpleDateFormat(
        return "IMG"
                + dateFormat.format(new Date(System.currentTimeMillis()))
                + ".jpg";
    }//from  w  ww. j  ava2 s  .  com


  1. makeFileName(String prefix, String filename)
  2. getLocalDateTimeForFileName(Date date)
  3. getJpegFileName(long fileNumber)
  4. getMetadataFileName(long fileNumber)
  5. getYuvFileName(long fileNumber)