Android File Create createNewFile(String filePath)

Here you can find the source of createNewFile(String filePath)

Description

create New File

Declaration

public static void createNewFile(String filePath) 

Method Source Code

//package com.java2s;
import java.io.File;
import java.io.IOException;

public class Main {
    public static void createNewFile(String filePath) {
        File file = new File(filePath);

        try {//from   w ww  . j av  a 2 s  .  co  m
            file.createNewFile();
        } catch (IOException e) {
            // TODO Auto-generated catch block
            e.printStackTrace();
        }
    }
}

Related

  1. createFileInFolder(File folder, String fileName)
  2. createFileInFolder(File folder, String fileName)
  3. createIfNoExist(String path)
  4. createNewFile(File file)
  5. createNewFile(String filePath)
  6. createNewFile(String filepath)
  7. createNewFileOnExist(String filePath)
  8. createSequenceFileName(String prefix, int sequenceNumber, int padTo, String suffix)
  9. ensureWorldReadable(File f)