Class EnergySchemeSet
Object
org.anchoranalysis.mpp.feature.energy.scheme.EnergySchemeSet
- All Implemented Interfaces:
Iterable<SimpleNameValue<EnergyScheme>>
public class EnergySchemeSet extends Object implements Iterable<SimpleNameValue<EnergyScheme>>
A set of
EnergySchemes, each associated with a unique name.
SharedFeatures are also associated with this set.
- Author:
- Owen Feehan
-
Constructor Summary
Constructors Constructor Description EnergySchemeSet(SharedFeatures sharedFeatures) -
Method Summary
Modifier and Type Method Description booleanadd(String name, EnergyScheme energyScheme)Adds a newEnergySchemeto the set with the given name.SimpleNameValue<EnergyScheme>get(String name)Retrieves anEnergySchemeby its name.SharedFeaturesgetSharedFeatures()Shared features associated with all energy schemes in the set.Iterator<SimpleNameValue<EnergyScheme>>iterator()
-
Constructor Details
-
Method Details
-
add
Adds a newEnergySchemeto the set with the given name.- Parameters:
name- the unique name for the energy schemeenergyScheme- theEnergySchemeto add- Returns:
- true if the energy scheme was successfully added
-
get
Retrieves anEnergySchemeby its name.- Parameters:
name- the name of the energy scheme to retrieve- Returns:
- the
SimpleNameValuecontaining the namedEnergyScheme, or null if not found
-
iterator
- Specified by:
iteratorin interfaceIterable<SimpleNameValue<EnergyScheme>>
-
getSharedFeatures
Shared features associated with all energy schemes in the set.
-