|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectlio.individuals.Individual
public abstract class Individual
This abstract class contains the common features and methods for each kind of individual.
Field Summary | |
---|---|
protected boolean |
evaluated
Determines whether the individual has been evaluated or not. |
protected static int |
maxSize
Maximum size of the individuals. |
protected int |
size
Current size of each individuals. |
protected double |
value
Numeric result of the evaluation of the individual. |
Constructor Summary | |
---|---|
Individual()
|
Method Summary | |
---|---|
void |
change()
Notifies a change in the individual's data. |
abstract java.lang.Object |
clone()
Clones an individual. |
int |
compareTo(java.lang.Object o)
Compares this Individual with the specified individual for order. |
static int |
getMaxSize()
Returns the maximum size that can have an individual. |
int |
getSize()
Returns the size of the individual. |
boolean |
isEvaluated()
Returns true if the individual has been already evaluated. |
static void |
setMaxSize(int pMaxSize)
Setter for property size. |
void |
setSize(int size)
Setter for property size. |
void |
setValue(double pValue,
boolean pEvaluated)
Sets value without carryng out the evaluation. |
abstract java.lang.String |
toString()
Returns a string representation of the individual. |
double |
value()
Returns the value corresponding to the evaluation of the individual. |
Methods inherited from class java.lang.Object |
---|
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
protected static int maxSize
protected int size
protected boolean evaluated
protected double value
Constructor Detail |
---|
public Individual()
Method Detail |
---|
public boolean isEvaluated()
public double value()
public void change()
public abstract java.lang.Object clone()
clone
in class java.lang.Object
public int getSize()
public static int getMaxSize()
public abstract java.lang.String toString()
toString
in class java.lang.Object
public void setSize(int size)
size
- New value of property size.public static void setMaxSize(int pMaxSize)
size
- New value of property size.public int compareTo(java.lang.Object o)
compareTo
in interface java.lang.Comparable
public void setValue(double pValue, boolean pEvaluated)
pValue
- the evaluation value for this object.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |