com.rubecula.darwin.domain.helper
Interface Chromosome

All Superinterfaces:
net.sf.tostring0.Identifiable, net.sf.tostring0.IToString, Progenitor, SexLinked
All Known Implementing Classes:
Chromosome_, Chromosome_NoSex, Chromosome_Sex, Genomic_Asexual

public interface Chromosome
extends net.sf.tostring0.IToString, SexLinked, Progenitor, net.sf.tostring0.Identifiable

Defines part of a Genomic.

Version:
$Revision: 1.9 $
Author:
Robin Hillyard

Field Summary
static java.lang.String SEX
          sex
 
Fields inherited from interface net.sf.tostring0.IToString
ANGBR_OPEN, ANGBRA_CLSE, BRA_CLSE, BRA_OPEN, BRCE_OPEN, BRCS_CLSE, COLON, LIST_SEPARATOR, MAX_ELEMENTS_DEFAULT, S_MT, S_PERCENT, SEPARATOR, SPACE
 
Method Summary
 void addLocus(int index, Locus locus)
          Method to add a Locus at the specified index.
 boolean addLocus(Locus locus)
          Method to add a Locus at the end of this Genomic.
 int getCount()
           
 Genomic getGenomic()
           
 java.util.Collection<Locus> getLoci()
          Getter/setter typically used by reflection.
 Locus getLocus(int index)
           
 void setGenomic(Genomic genomic)
           
 void setLoci(java.util.Collection<Locus> loci)
          This is now the preferred method to set the loci.
 
Methods inherited from interface net.sf.tostring0.IToString
toString, toStringBrief, toStringId
 
Methods inherited from interface com.rubecula.darwin.domain.helper.SexLinked
isSexLinked
 
Methods inherited from interface net.sf.tostring0.Identifiable
getIdentifier
 

Field Detail

SEX

static final java.lang.String SEX
sex

See Also:
Constant Field Values
Method Detail

addLocus

void addLocus(int index,
              Locus locus)
              throws GeneticsException
Method to add a Locus at the specified index.

Parameters:
index - the index at which the new object will appear.
locus - a locus to be inserted into this Genomic.
Throws:
GeneticsException
See Also:
List.add(int, java.lang.Object)

addLocus

boolean addLocus(Locus locus)
                 throws GeneticsException
Method to add a Locus at the end of this Genomic.

Parameters:
locus - a locus to be inserted into this Genomic.
Returns:
true if the locus is added successfully.
Throws:
GeneticsException
See Also:
addLocus(int, Locus)

getCount

int getCount()
Returns:
the number of loci in this chromosome

getGenomic

Genomic getGenomic()
Returns:
the Genomic to which this chromosome belongs.

getLoci

java.util.Collection<Locus> getLoci()
Getter/setter typically used by reflection.

Returns:
the loci as a collection of Locus objects.

getLocus

Locus getLocus(int index)
Parameters:
index -
Returns:
the locus defined by index (0..N)

setGenomic

void setGenomic(Genomic genomic)
Parameters:
genomic -

setLoci

void setLoci(java.util.Collection<Locus> loci)
This is now the preferred method to set the loci. Any prior loci will be forgotten. Getter/setter typically used by reflection.

Parameters:
loci -


Copyright © 2010 Rubecula Software, LLC. All Rights Reserved.