de.cesr.lara.components.decision.impl
Class LLightBoRow<BO extends LaraBehaviouralOption<?,?>>
java.lang.Object
de.cesr.lara.components.decision.impl.LLightBoRow<BO>
- All Implemented Interfaces:
- LaraBoRow<BO>
public class LLightBoRow<BO extends LaraBehaviouralOption<?,?>>
- extends Object
- implements LaraBoRow<BO>
This implementation of LaraBoRow
does not store values for every
preference but only the sum. Therefore, it may not be suitable for any
comprehensive deliberative choice component or post-processing.
bo
protected BO extends LaraBehaviouralOption<?,?> bo
utilitySum
protected double utilitySum
LLightBoRow
public LLightBoRow(BO bo)
- Parameters:
bo
- behavioural option
LLightBoRow
public LLightBoRow(BO bo,
double utilitySum)
- Parameters:
bo
- behavioural optionutilitySum
- sum of all individual utility values
getBehaviouralOption
public BO getBehaviouralOption()
- Specified by:
getBehaviouralOption
in interface LaraBoRow<BO extends LaraBehaviouralOption<?,?>>
- Returns:
- the behavioural option this row represents
- See Also:
LaraBoRow.getBehaviouralOption()
getIndividualUtilityValue
public double getIndividualUtilityValue(Class<? extends LaraPreference> preference)
- Description copied from interface:
LaraBoRow
- Provides the individual utility values regarding the given preference.
- Specified by:
getIndividualUtilityValue
in interface LaraBoRow<BO extends LaraBehaviouralOption<?,?>>
- Returns:
- individual utility value
- See Also:
LaraBoRow.getIndividualUtilityValue(java.lang.Class)
getSum
public double getSum()
- Specified by:
getSum
in interface LaraBoRow<BO extends LaraBehaviouralOption<?,?>>
- Returns:
- the sum of all individual utility values
- See Also:
LaraBoRow.getSum()
setIndividualUtilityValue
public void setIndividualUtilityValue(Class<? extends LaraPreference> preference,
double value)
- Description copied from interface:
LaraBoRow
- Adds a individual utility values regarding a given preference.
- Specified by:
setIndividualUtilityValue
in interface LaraBoRow<BO extends LaraBehaviouralOption<?,?>>
- See Also:
LaraBoRow.setIndividualUtilityValue(java.lang.Class,
double)
toString
public String toString()
- Overrides:
toString
in class Object