com.izforge.izpack.util
Class TemporaryDirectory

java.lang.Object
  extended by com.izforge.izpack.util.TemporaryDirectory
All Implemented Interfaces:
CleanupClient

public class TemporaryDirectory
extends Object
implements CleanupClient

Manages the life-cycle of a temporary directory


Constructor Summary
TemporaryDirectory(Info.TempDir tempDirDescription, InstallData installData, Housekeeper housekeeper)
          Define a temporary directory
 
Method Summary
 void cleanUp()
          Deletes the temporary directory and all it's contents immediately
 void create()
          Creates the temporary directory and sets the install data variable to point to it
 void deleteOnExit()
          Configure this temporary directory to be deleted when the installer exits This will delete the directory and all of its contents
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

TemporaryDirectory

public TemporaryDirectory(Info.TempDir tempDirDescription,
                          InstallData installData,
                          Housekeeper housekeeper)
Define a temporary directory

Parameters:
tempDirDescription - describes the parameters of the directory to be created
installData - The install data in to which the temporary directories variable will be written
housekeeper - the house-keeper
Method Detail

create

public void create()
            throws IOException
Creates the temporary directory and sets the install data variable to point to it

Throws:
IOException - if creation of the directory fails

deleteOnExit

public void deleteOnExit()
Configure this temporary directory to be deleted when the installer exits This will delete the directory and all of its contents


cleanUp

public void cleanUp()
Deletes the temporary directory and all it's contents immediately

Specified by:
cleanUp in interface CleanupClient


Copyright © 2018. All rights reserved.