Class ParamFromCollection<T extends FeatureInput>

Object
AnchorBean<Feature<T>>
InitializableBean<Feature<T>, FeatureInitialization>
Feature<T>
FeatureGeneric<T>
ParamFromCollection<T>
Type Parameters:
T - feature-input-type

public class ParamFromCollection<T extends FeatureInput> extends FeatureGeneric<T>
Retrieves a parameter as stored in a Dictionary in SharedObjects.

This differs from FromDictionary which reads the parameter from the energy-stack, whereas this from a specific parameters collection.

Author:
Owen Feehan
  • Constructor Summary

    Constructors
    Constructor
    Description
     
  • Method Summary

    Modifier and Type
    Method
    Description
    protected void
    beforeCalc(FeatureInitialization initialization)
     
    double
    calculate(FeatureCalculationInput<T> input)
     
    The name of the Dictionary that will be retrieved from SharedObjects.
    The name of the key in the dictionary, whose corresponding value will be returned.
    void
    setDictionary(String dictionary)
    The name of the Dictionary that will be retrieved from SharedObjects.
    void
    The name of the key in the dictionary, whose corresponding value will be returned.

    Methods inherited from class org.anchoranalysis.feature.bean.operator.FeatureGeneric

    inputType

    Methods inherited from class org.anchoranalysis.feature.bean.Feature

    assignTo, calculateCheckInitialized, castAs, createListChildFeatures, describeBean, describeParameters, descriptionLong, duplicateChangeName, getCustomName, getFriendlyName, onInitialization, setCustomName, toString

    Methods inherited from class org.anchoranalysis.bean.initializable.InitializableBean

    getInitialization, getLogger, getPropertyInitializer, initialize, initializeRecursive, initRecursiveWithInitializer, isInitialized

    Methods inherited from class org.anchoranalysis.bean.AnchorBean

    checkMisconfigured, describeChildren, duplicateBean, fields, findFieldsOfClass, getBeanName, getLocalPath, localise

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
  • Constructor Details

    • ParamFromCollection

      public ParamFromCollection()
  • Method Details

    • beforeCalc

      protected void beforeCalc(FeatureInitialization initialization) throws InitializeException
      Overrides:
      beforeCalc in class Feature<T extends FeatureInput>
      Throws:
      InitializeException
    • calculate

      public double calculate(FeatureCalculationInput<T> input) throws FeatureCalculationException
      Specified by:
      calculate in class Feature<T extends FeatureInput>
      Throws:
      FeatureCalculationException
    • getDictionary

      public String getDictionary()
      The name of the Dictionary that will be retrieved from SharedObjects.
    • setDictionary

      public void setDictionary(String dictionary)
      The name of the Dictionary that will be retrieved from SharedObjects.
    • getKey

      public String getKey()
      The name of the key in the dictionary, whose corresponding value will be returned.
    • setKey

      public void setKey(String key)
      The name of the key in the dictionary, whose corresponding value will be returned.