Class AbstractCompoundSet<C extends Compound>
java.lang.Object
org.biojava3.core.sequence.template.AbstractCompoundSet<C>
- Type Parameters:
C- The compound this set will contain
- All Implemented Interfaces:
CompoundSet<C>
- Direct Known Subclasses:
AbstractNucleotideCompoundSet
public abstract class AbstractCompoundSet<C extends Compound>
extends Object
implements CompoundSet<C>
- Author:
- Andy Yates
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbooleancompoundsEqual(C compoundOne, C compoundTwo) booleancompoundsEquivalent(C compoundOne, C compoundTwo) booleangetCompoundForString(String string) Return null if not recognised.getEquivalentCompounds(C compound) intReturns the maximum size of a compound String this set holdsgetStringForCompound(C compound) booleanhasCompound(C compound) inthashCode()booleanbooleanReturns true if all String representations of Compounds are of the same length.voidverifySequence(Sequence<C> sequence)
-
Constructor Details
-
AbstractCompoundSet
public AbstractCompoundSet()
-
-
Method Details
-
getStringForCompound
- Specified by:
getStringForCompoundin interfaceCompoundSet<C extends Compound>
-
getCompoundForString
Description copied from interface:CompoundSetReturn null if not recognised. Throw IllegalArgumentException if string is longer than maximum allowed byCompoundSet.getStringForCompound(Compound).- Specified by:
getCompoundForStringin interfaceCompoundSet<C extends Compound>
-
getMaxSingleCompoundStringLength
public int getMaxSingleCompoundStringLength()Description copied from interface:CompoundSetReturns the maximum size of a compound String this set holds- Specified by:
getMaxSingleCompoundStringLengthin interfaceCompoundSet<C extends Compound>
-
isCompoundStringLengthEqual
public boolean isCompoundStringLengthEqual()Description copied from interface:CompoundSetReturns true if all String representations of Compounds are of the same length.- Specified by:
isCompoundStringLengthEqualin interfaceCompoundSet<C extends Compound>
-
hasCompound
- Specified by:
hasCompoundin interfaceCompoundSet<C extends Compound>
-
compoundsEquivalent
- Specified by:
compoundsEquivalentin interfaceCompoundSet<C extends Compound>
-
getEquivalentCompounds
- Specified by:
getEquivalentCompoundsin interfaceCompoundSet<C extends Compound>
-
compoundsEqual
-
verifySequence
- Specified by:
verifySequencein interfaceCompoundSet<C extends Compound>- Throws:
CompoundNotFoundError
-
getAllCompounds
- Specified by:
getAllCompoundsin interfaceCompoundSet<C extends Compound>
-
isComplementable
public boolean isComplementable()- Specified by:
isComplementablein interfaceCompoundSet<C extends Compound>
-
hashCode
public int hashCode() -
equals
-