|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object net.sf.tostring0.AToString com.rubecula.darwin.domain.helper.Attribute_ com.rubecula.darwin.domain.genetics.Allele_
public abstract class Allele_
This abstract provides base operations for implementations of Allele
,
which are specific, competing genes which may appear at a Locus
.
In general, an allele can have a key and a value, both being objects. If the
key is null, then the value, reduced to a String, serves as its key.
Normally, known alleles are defined via configuration. But new alleles
(mutants) can arise during an evolution. For these, there is an
AlleleFactory
.
In all cases, however, an Allele is immutable regarding its value. Once constructed, the value cannot be changed. The value of the (parent) locus is set once and once only.
Field Summary | |
---|---|
protected static org.apache.commons.logging.Log |
LOG
The logger for this class. |
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 |
Constructor Summary | |
---|---|
protected |
Allele_(java.lang.Object value)
Constructor of an Allele_ based on a specific value. |
protected |
Allele_(java.lang.Object key,
java.lang.Object value)
Primary Private constructor of an Allele_ based on a specific value. |
Method Summary | |
---|---|
boolean |
censusMe(Census census,
java.lang.Object context)
Method to census this object. |
java.util.Collection<? extends Censusible> |
getCensusibleChildren()
Method to return a list of censusible children of this object. |
Locus |
getLocus()
Return the value of locus . |
java.lang.String |
getSignature()
|
protected int |
getStringChars()
|
void |
setLocus(Locus locus)
Set the value of the locus for this Allele. |
void |
setStringChars(int stringChars)
Set the number of characters that we should see when we create a string of this Allele . |
void |
setValue(java.lang.Object value)
set the field Attribute_.value . |
java.lang.String |
toString(boolean showDetail,
boolean showClass,
boolean showIdentifier,
boolean includeParent,
boolean includeChildren,
java.lang.String prefix,
boolean recurse,
int maxElements,
int maxChars)
|
Methods inherited from class com.rubecula.darwin.domain.helper.Attribute_ |
---|
equals, getAttribute, getIdentifier, getValue, hashCode |
Methods inherited from class net.sf.tostring0.AToString |
---|
toString, toStringBrief, toStringId |
Methods inherited from class java.lang.Object |
---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
Methods inherited from interface com.rubecula.darwin.domain.helper.Attribute |
---|
getAttribute, getValue |
Methods inherited from interface net.sf.tostring0.IToString |
---|
toStringBrief, toStringId |
Methods inherited from interface com.rubecula.darwin.domain.helper.Basic |
---|
getBases |
Methods inherited from interface net.sf.tostring0.Identifiable |
---|
getIdentifier |
Field Detail |
---|
protected static final org.apache.commons.logging.Log LOG
Constructor Detail |
---|
protected Allele_(java.lang.Object value)
value
- the value for the new Allele_, as an Object.protected Allele_(java.lang.Object key, java.lang.Object value)
key
- the key for the new Allele_, as an Object.value
- the value for the new Allele_, as an Object.Method Detail |
---|
public boolean censusMe(Census census, java.lang.Object context)
Censusible
censusMe
in interface Censusible
census
- the census object which will present the results of taking
this censuscontext
- an arbitrary object which can be used by the census object to
provide appropriate context for this object.
Censusible.getCensusibleChildren()
.Censusible.censusMe(com.rubecula.darwin.domain.helper.Census,
java.lang.Object)
public java.util.Collection<? extends Censusible> getCensusibleChildren()
Censusible
getCensusibleChildren
in interface Censusible
ArrayList
of censusible objects.Censusible.getCensusibleChildren()
public Locus getLocus()
locus
.
getLocus
in interface Allele
Allele.getLocus()
public java.lang.String getSignature()
getSignature
in interface CacheSignature
CacheSignature.getSignature()
public void setLocus(Locus locus)
setLocus
in interface Allele
Allele.setLocus(com.rubecula.darwin.domain.helper.Locus)
public void setStringChars(int stringChars)
Allele
. By default, the number is 1. We only increase it
to N+1 if there are allele identifiers that share the first N characters.
stringChars
- the stringChars to setpublic void setValue(java.lang.Object value)
Attribute_
Attribute_.value
.
setValue
in interface Attribute
setValue
in class Attribute_
value
- the new value for the attribute.Attribute_.setValue(java.lang.Object)
public java.lang.String toString(boolean showDetail, boolean showClass, boolean showIdentifier, boolean includeParent, boolean includeChildren, java.lang.String prefix, boolean recurse, int maxElements, int maxChars)
toString
in interface net.sf.tostring0.IToString
toString
in class Attribute_
Attribute_.toString(boolean,
boolean, boolean, boolean, boolean, java.lang.String, boolean, int,
int)
protected int getStringChars()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |