public class AcsCWD
extends java.lang.Object
Note that using files goes very much against ALMA's idea of location transparency of component locations, and against having a central archive to store data. This class should only be used in exceptional situations, such as for offline data reduction, or for other inevitable temporary file storage, where a component creates and deletes the files within its life cycle. Files should almost never be used for inter-component communication!
Note that on a diskless machine, the file created may well be located on a RAM disk and does not survive machine rebooting.
| Constructor and Description |
|---|
AcsCWD() |
| Modifier and Type | Method and Description |
|---|---|
static java.io.File |
createTempFileInCWD(java.lang.String prefix,
java.lang.String suffix)
Creates a temp file in the current working dir.
|
static java.io.File |
getCWD()
Gets the current working directory.
|
static void |
setCWD(java.lang.String cwd)
Sets the current working directory.
|
public static java.io.File getCWD()
public static void setCWD(java.lang.String cwd)
cwd - public static java.io.File createTempFileInCWD(java.lang.String prefix,
java.lang.String suffix)
throws java.io.IOException
prefix - The prefix string to be used in generating the file's
name; must be at least three characters longsuffix - The suffix string to be used in generating the file's
name; may be null, in which case the
suffix ".tmp" will be usedjava.io.IOExceptionFile.createTempFile(java.lang.String, java.lang.String, java.io.File)