Class FeatureEvaluator<T extends FeatureInput>
Object
- Type Parameters:
T
- feature input-type
public class FeatureEvaluator<T extends FeatureInput>
extends FeatureRelatedBean<FeatureEvaluator<T>>
Defines a feature and provides a means to calculate inputs for it, a session.
Optionally, an energy stack can be associated with these inputs.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoid
checkMisconfigured
(BeanInstanceMap defaultInstances) Checks that a bean's properties conform to expectations.Creates session for evaluatingfeature
optionally adding an energy-stack.The specified energy stack.Parameters to optionally associated withstackEnergy
, and meaningless ifstackEnergy
is not specified.The single feature that will be calculated (possibly repeatedly) in the session.The single feature that will be calculated (possibly repeatedly) in the sessionOptionally specifies an energy-stack to be associated with every calculation input.void
setDictionary
(DictionaryProvider dictionary) Parameters to optionally associated withstackEnergy
, and meaningless ifstackEnergy
is not specified.void
setFeature
(Feature<T> feature) The single feature that will be calculated (possibly repeatedly) in the session.void
setFeatureProvider
(FeatureProvider<T> featureProvider) The single feature that will be calculated (possibly repeatedly) in the sessionvoid
setStackEnergy
(Provider<Stack> stackEnergy) Optionally specifies an energy-stack to be associated with every calculation input.Methods inherited from class org.anchoranalysis.bean.initializable.InitializableBean
getInitialization, getLogger, getPropertyInitializer, initialize, initializeRecursive, initRecursiveWithInitializer, isInitialized, onInitialization
Methods inherited from class org.anchoranalysis.bean.AnchorBean
describeBean, describeChildren, duplicateBean, fields, findFieldsOfClass, getBeanName, getLocalPath, localise, toString
-
Constructor Details
-
FeatureEvaluator
public FeatureEvaluator()
-
-
Method Details
-
checkMisconfigured
Description copied from class:AnchorBean
Checks that a bean's properties conform to expectations.- Overrides:
checkMisconfigured
in classAnchorBean<FeatureEvaluator<T extends FeatureInput>>
- Parameters:
defaultInstances
- all available default instances if theDefaultInstance
annotation is used- Throws:
BeanMisconfiguredException
- if the bean has not been configured properly as XML
-
createFeatureSession
Creates session for evaluatingfeature
optionally adding an energy-stack.- Returns:
- the calculator for a newly created session.
- Throws:
OperationFailedException
- if the session creation fails
-
energyStack
The specified energy stack.- Returns:
- the energy stack if it is specified.
- Throws:
OperationFailedException
- if the energy-stack is specified but cannot be created.
-
getFeature
The single feature that will be calculated (possibly repeatedly) in the session.Either this field must be set or
featureProvider
, but not both. -
setFeature
The single feature that will be calculated (possibly repeatedly) in the session.Either this field must be set or
featureProvider
, but not both. -
getFeatureProvider
The single feature that will be calculated (possibly repeatedly) in the sessionEither this field must be set or
feature
, but not both. -
setFeatureProvider
The single feature that will be calculated (possibly repeatedly) in the sessionEither this field must be set or
feature
, but not both. -
getStackEnergy
Optionally specifies an energy-stack to be associated with every calculation input. -
setStackEnergy
Optionally specifies an energy-stack to be associated with every calculation input. -
getDictionary
Parameters to optionally associated withstackEnergy
, and meaningless ifstackEnergy
is not specified.
-