Package org.eclipse.cdt.utils.envvar

# Class StorableEnvironmentLoader

java.lang.Object
org.eclipse.cdt.utils.envvar.StorableEnvironmentLoader

public abstract class StorableEnvironmentLoader extends Object
This class implements the common functionality that allows storing and loading environment variable settings from eclipse properties

Since:
  3.0

## Nested Class Summary

Nested Classes
Modifier and Type
Class
Description
`static interface`
`StorableEnvironmentLoader.ISerializeInfo`
this interface represents the preference node and the preference name that are used for holding the environment data

## Constructor Summary

Constructors
Constructor
Description
`StorableEnvironmentLoader()`

## Method Summary

Modifier and Type
Method
Description
`StorableEnvironment`
`cloneEnvironmentWithContext(Object context, StorableEnvironment base, boolean isReadOnly)`
Creates the StorableEnvironment clone for a new configuration, say, based on an existing configuration
`protected abstract StorableEnvironmentLoader.ISerializeInfo`
`getSerializeInfo(Object context)`
this method should return the ISerializeInfo representing the information of where the variable should be stored and loaded If the given context is not supported this method should return null
`protected StorableEnvironment`
`loadEnvironment(Object context, boolean readOnly)`
Loads the environment from the context's `StorableEnvironmentLoader.ISerializeInfo`.
`protected void`
`storeEnvironment(StorableEnvironment env, Object context, boolean force, boolean flush)`

### Methods inherited from class java.lang.Object

`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

## Constructor Details

### StorableEnvironmentLoader

public StorableEnvironmentLoader()

## Method Details

### cloneEnvironmentWithContext

public StorableEnvironment cloneEnvironmentWithContext(Object context, StorableEnvironment base, boolean isReadOnly)
Creates the StorableEnvironment clone for a new configuration, say, based on an existing configuration

Parameters:
  `context` - the configuration / workspace context the configuration is to be cloned for
  `base` - the base environment to copy
Returns:
  a StorableEnvironment clone of the configuration's environment
Since:
  5.2

### getSerializeInfo

protected abstract StorableEnvironmentLoader.ISerializeInfo getSerializeInfo(Object context)
this method should return the ISerializeInfo representing the information of where the variable should be stored and loaded If the given context is not supported this method should return null

### loadEnvironment

protected StorableEnvironment loadEnvironment(Object context, boolean readOnly)
Loads the environment from the context's `StorableEnvironmentLoader.ISerializeInfo`. NB the environment in the `StorableEnvironmentLoader.ISerializeInfo` need not be available yet. The `StorableEnvironmentLoader.ISerializeInfo` may be held by the `StorableEnvironment` to pick up any external changes in the environment.

Parameters:
  `context` -
  `readOnly` -
Returns:
  StorableEnvironment

### storeEnvironment

protected void storeEnvironment(StorableEnvironment env, Object context, boolean force, boolean flush) throws org.eclipse.core.runtime.CoreException

Throws:
  `org.eclipse.core.runtime.CoreException`