Java Temp Directory Get getTempDirectory()

Here you can find the source of getTempDirectory()

Description

Returns the java.io.tmpdir property.

License

Open Source License

Return

the default temp dir

Declaration

public static File getTempDirectory() 

Method Source Code

//package com.java2s;
/*******************************************************************************
 * Copyright (c) 2006-2010 eBay Inc. All Rights Reserved.
 * Licensed under the Apache License, Version 2.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *    http://www.apache.org/licenses/LICENSE-2.0
 *******************************************************************************/

import java.io.File;

public class Main {
    /**/* ww  w .j  a  v  a  2  s . c o  m*/
     * Returns the java.io.tmpdir property. Clients are advised to use this
     * wrapper because at a later stage we can easily change this location.
     * 
     * @return the default temp dir
     */
    public static File getTempDirectory() {
        return new File(System.getProperty("java.io.tmpdir"));
    }
}

Related

  1. getTempDir(String suffix)
  2. getTempDirectory()
  3. getTempDirectory()
  4. getTempDirectory()
  5. getTempDirectory()
  6. getTempDirectory()
  7. getTempDirectory()
  8. getTempDirectory()
  9. getTempDirectory()