eaLib API Docs
Last Modified : January 7 2002

mss.ea.chr
Class Chromosome

java.lang.Object
  |
  +--mss.ea.chr.Chromosome
All Implemented Interfaces:
java.lang.Cloneable, java.io.Serializable
Direct Known Subclasses:
ArrayChromosome, BinaryStringChromosome, DoubleChromosome, FloatChromosome, IntegerChromosome, ListChromosome, LongChromosome, NullChromosome, StringChromosome, TreeChromosome

public abstract class Chromosome
extends java.lang.Object
implements java.lang.Cloneable, java.io.Serializable

Abstract base class for a chromosome.

Since:
0.1
Version:
$Revision: 1.6 $ $Date: 2001/11/22 12:49:13 $
Author:
Andreas Rummler
See Also:
Serialized Form

Field Summary
protected  java.lang.Object co
          Single object, containing the chromosome.
 
Constructor Summary
Chromosome(java.lang.Object chrObject)
          Constructor with chromosome object.
 
Method Summary
abstract  java.lang.Object clone()
          Clones this chromosome.
abstract  boolean equals(java.lang.Object o)
          Test for equality.
 java.lang.Object getChromosomeObject()
          Deprecated. replaced by getObject
 java.lang.Object getObject()
          Gets the current chromosome object.
 void setChromosomeObject(java.lang.Object chrObject)
          Deprecated. replaced by setObject
 void setObject(java.lang.Object chrObject)
          Sets a new chromosome object.
 java.lang.String toString()
          Returns a string representation of this chromosome.
 
Methods inherited from class java.lang.Object
finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

co

protected java.lang.Object co
Single object, containing the chromosome.
Constructor Detail

Chromosome

public Chromosome(java.lang.Object chrObject)
Constructor with chromosome object.
Parameters:
chrObject - chromosome object
Method Detail

setObject

public void setObject(java.lang.Object chrObject)
Sets a new chromosome object.
Parameters:
chrObject - new chromosome object

setChromosomeObject

public void setChromosomeObject(java.lang.Object chrObject)
Deprecated. replaced by setObject

Sets a new chromosome object.
Parameters:
chrObject - new chromosome object

getObject

public java.lang.Object getObject()
Gets the current chromosome object.
Returns:
current chromosome object

getChromosomeObject

public java.lang.Object getChromosomeObject()
Deprecated. replaced by getObject

Gets the current chromosome object.
Returns:
current chromosome object

toString

public java.lang.String toString()
Returns a string representation of this chromosome.
Overrides:
toString in class java.lang.Object
Returns:
string representation

clone

public abstract java.lang.Object clone()
Clones this chromosome.
Overrides:
clone in class java.lang.Object
Returns:
new chromosome, containing the same information as the current chromosome

equals

public abstract boolean equals(java.lang.Object o)
Test for equality. This method must overloaded to ensure an appropriate equality tests. This method returns true if two chromosomes contain the same contents, they need not to be the same objects.
Overrides:
equals in class java.lang.Object
Parameters:
o - object to compare to
Returns:
true, if both chromosomes are holding the same information

eaLib API Docs
Last Modified : January 7 2002

Copyright © 2000-2001 Technical University of Ilmenau, Department ESS