Modifier and Type | Field and Description |
---|---|
protected double[] |
array |
protected java.util.SortedMap<Objective,Value<?>> |
map |
Constructor and Description |
---|
Objectives() |
Modifier and Type | Method and Description |
---|---|
void |
add(Objective objective,
double value)
Adds the objective with the specified double value.
|
void |
add(Objective objective,
int value)
Adds the objective with the specified integer value.
|
void |
add(Objective objective,
Value<?> value)
Adds the objective with the specified value.
|
void |
add(java.lang.String name,
Objective.Sign sign,
double value)
Adds the objective with the specified value.
|
void |
add(java.lang.String name,
Objective.Sign sign,
int value)
Adds the objective with the specified value.
|
void |
add(java.lang.String name,
Objective.Sign sign,
Value<?> value)
Adds the objective with the specified value.
|
void |
addAll(Objectives objectives)
Adds all objective with the specified value specified in
Objectives . |
double[] |
array()
Returns an array of all values which all have to be minimized.
|
double |
distance(Objectives other)
Calculates the euclidean distance of two
Objectives . |
boolean |
dominates(Objectives opponent)
Returns
true if this objectives dominate the specified
objectives. |
Value<?> |
get(Objective objective)
Returns the value that is assigned to the given objective.
|
Objective |
get(Value<?> value)
Returns the objective that is assigned to the given value.
|
java.util.Collection<Objective> |
getKeys()
Returns all objectives.
|
java.util.Collection<Value<?>> |
getValues()
Returns all values.
|
boolean |
isEqual(Objectives opponent)
Returns
true if this objectives are equal to the specified
objectives. |
java.util.Iterator<java.util.Map.Entry<Objective,Value<?>>> |
iterator() |
int |
size()
Returns the number of set
Objective s. |
protected void |
submit()
Calculates the array.
|
java.lang.String |
toString() |
boolean |
weaklyDominates(Objectives opponent)
Returns
true if this objectives weakly dominates the specified
objectives. |
public double[] array()
Value.getDouble()
protected void submit()
public int size()
Objective
s.public java.util.Collection<Objective> getKeys()
public java.util.Collection<Value<?>> getValues()
public Value<?> get(Objective objective)
null
if the objective does not exist.objective
- the given objectivepublic Objective get(Value<?> value)
null
if the value does not exist.value
- the given valuepublic void add(Objective objective, Value<?> value)
objective
- the objectivevalue
- the valuepublic void add(java.lang.String name, Objective.Sign sign, Value<?> value)
name
- the name of the objectivesign
- the optimization directionvalue
- the valuepublic void add(Objective objective, double value)
objective
- the objectivevalue
- the valuepublic void add(java.lang.String name, Objective.Sign sign, double value)
name
- the name of the objectivesign
- the optimization directionvalue
- the valuepublic void add(Objective objective, int value)
objective
- the objectivevalue
- the valuepublic void add(java.lang.String name, Objective.Sign sign, int value)
name
- the name of the objectivesign
- the optimization directionvalue
- the valuepublic void addAll(Objectives objectives)
Objectives
.objectives
- the objectivespublic boolean weaklyDominates(Objectives opponent)
true
if this objectives weakly dominates the specified
objectives. This comparison is based on the array()
values.opponent
- other objectivestrue
if this objectives weakly dominate the
opponent
public boolean dominates(Objectives opponent)
true
if this objectives dominate the specified
objectives. This comparison is based on the array()
values.opponent
- other objectivestrue
if these objectives dominate the opponent
public boolean isEqual(Objectives opponent)
true
if this objectives are equal to the specified
objectives. This comparison is based on the array()
values.opponent
- other objectivestrue
if these objectives dominate the opponent
public double distance(Objectives other)
Objectives
. This
calculation is based on the array()
values.other
- the second objectivespublic java.lang.String toString()
toString
in class java.lang.Object