Here you can find the source of getTempDirURL()
public static String getTempDirURL()
//package com.java2s; //License from project: Open Source License public class Main { /**/*w w w. java 2 s.c om*/ * Get the absolute url of a os specific temp directory * @return absolute url of a temp directory */ public static String getTempDirURL() { String tempdir = System.getProperty("java.io.tmpdir"); if (!(tempdir.endsWith("/") || tempdir.endsWith("\\"))) { tempdir = tempdir + System.getProperty("file.separator"); } return tempdir; } }