Java Temp Directory Get getTempDir()

Here you can find the source of getTempDir()

Description

get Temp Dir

License

Open Source License

Declaration

public static File getTempDir() 

Method Source Code

//package com.java2s;
/*******************************************************************************
 * Copyright (c) 2014 Gabriel Skantze./*from   ww  w.java 2 s .c o m*/
 * All rights reserved. This program and the accompanying materials
 * are made available under the terms of the GNU Public License v3.0
 * which accompanies this distribution, and is available at
 * http://www.gnu.org/licenses/gpl.html
 * 
 * Contributors:
 *     Gabriel Skantze - initial API and implementation
 ******************************************************************************/

import java.io.File;

public class Main {
    public static File getTempDir() {
        return new File(System.getProperty("java.io.tmpdir")
                + File.separator + "iristk");
    }

    public static File getTempDir(String name) {
        return new File(System.getProperty("java.io.tmpdir")
                + File.separator + "iristk" + File.separator + name);
    }
}

Related

  1. getTempDir()
  2. getTempDir()
  3. getTempDir()
  4. getTempDir()
  5. getTempDir()
  6. getTempDir()
  7. getTempDir()
  8. getTempDir()
  9. getTempDir(File baseDir)