public class StorableEnvironment extends Object
Modifier and Type | Field and Description |
---|---|
static String |
ENVIRONMENT_ELEMENT_NAME |
Constructor and Description |
---|
StorableEnvironment(boolean isReadOnly)
Create new empty StorableEnvironment
|
StorableEnvironment(ICStorageElement element,
boolean isReadOnly)
Initialize the StorableEnvironment from an ICStorageElement tree
|
StorableEnvironment(IEnvironmentVariable[] variables,
boolean isReadOnly) |
StorableEnvironment(StorableEnvironment env,
boolean isReadOnly)
Copy constructor.
|
Modifier and Type | Method and Description |
---|---|
boolean |
appendContributedEnvironment() |
boolean |
appendEnvironment() |
IEnvironmentVariable |
checkVariable(String name,
String value,
int op,
String delimiter) |
IEnvironmentVariable |
createVariable(String name) |
IEnvironmentVariable |
createVariable(String name,
String value) |
IEnvironmentVariable |
createVariable(String name,
String value,
int op,
String delimiter) |
IEnvironmentVariable |
createVariable(String name,
String value,
String delimiter) |
void |
createVriables(IEnvironmentVariable[] vars) |
boolean |
deleteAll() |
IEnvironmentVariable |
deleteVariable(String name) |
IEnvironmentVariable |
getVariable(String name) |
IEnvironmentVariable[] |
getVariables() |
boolean |
isChanged()
Returns the "change" state of the environment.
|
boolean |
isDirty()
Returns the "dirty" state of the environment.
|
boolean |
isReadOnly() |
void |
restoreDefaults() |
void |
serialize(ICStorageElement element)
Serialize the Storable enviornment into the ICStorageElement
NB assumes that any variables part of the ISerializeInfo will continue to be serialized
|
void |
setAppendContributedEnvironment(boolean append) |
void |
setAppendEnvironment(boolean append) |
void |
setChanged(boolean changed)
sets the "change" state of the environment
|
void |
setDirty(boolean dirty)
sets the "dirty" state of the environment
|
void |
setVariales(IEnvironmentVariable[] vars)
Set the enviornment variables in this
StorableEnvironment |
public static final String ENVIRONMENT_ELEMENT_NAME
public StorableEnvironment(IEnvironmentVariable[] variables, boolean isReadOnly)
variables
- isReadOnly
- public StorableEnvironment(boolean isReadOnly)
isReadOnly
- public StorableEnvironment(StorableEnvironment env, boolean isReadOnly)
StorableEnvironmentLoader.ISerializeInfo
isn't copied
over, as it's expected this environment's settings will be stored elsewhereenv
- isReadOnly
- public StorableEnvironment(ICStorageElement element, boolean isReadOnly)
element
- isReadOnly
- public void serialize(ICStorageElement element)
element
- public IEnvironmentVariable createVariable(String name, String value, int op, String delimiter)
public IEnvironmentVariable createVariable(String name)
public IEnvironmentVariable createVariable(String name, String value)
public IEnvironmentVariable createVariable(String name, String value, String delimiter)
public IEnvironmentVariable checkVariable(String name, String value, int op, String delimiter)
public boolean isDirty()
true
, that means that the environment
is out of synch with the repository and the environment needs to be serialized.
false
when the environment is serialized
by calling the serialize() methodpublic void setDirty(boolean dirty)
dirty
- represents the new statepublic boolean isChanged()
false
only by calling the setChanged(false) methodpublic void setChanged(boolean changed)
changed
- represents the new "change" statepublic IEnvironmentVariable getVariable(String name)
name
- public void setVariales(IEnvironmentVariable[] vars)
StorableEnvironment
vars
- public void createVriables(IEnvironmentVariable[] vars)
public IEnvironmentVariable[] getVariables()
public IEnvironmentVariable deleteVariable(String name)
public boolean deleteAll()
public boolean isReadOnly()
public boolean appendEnvironment()
public void setAppendEnvironment(boolean append)
public boolean appendContributedEnvironment()
public void setAppendContributedEnvironment(boolean append)
public void restoreDefaults()
Copyright (c) IBM Corp. and others 2004, 2020. All Rights Reserved.