Package org.biojava.bio.symbol
Class DNAAmbPack
java.lang.Object
org.biojava.bio.symbol.DNAAmbPack
- All Implemented Interfaces:
Serializable
,Packing
Packing utility class for DNA. Also represents
ambiguity.
- Author:
- Matthew Pocock, David Huen (bugfix)
- See Also:
-
Constructor Summary
Constructors -
Method Summary
-
Constructor Details
-
DNAAmbPack
public DNAAmbPack()
-
-
Method Details
-
getAlphabet
Description copied from interface:Packing
The FiniteAlphabet this packing is for.- Specified by:
getAlphabet
in interfacePacking
- Returns:
- the FiniteAlphabet that we can pack
-
pack
Description copied from interface:Packing
Return a byte representing the packing of a symbol. The bits will be from 1 >> 0 through to 1 >> (wordSize - 1).
-
unpack
Description copied from interface:Packing
Return the symbol for a packing.
-
wordSize
Description copied from interface:Packing
The number of bits required to pack a symbol.
-
handlesAmbiguity
Description copied from interface:Packing
Flag to state if ambiguities are stored.
Packings are free to either store ambiguity information or to discard it (presumably converting all ambiguities to a standard AtomicSymbol and then packing that). You can check wether ambiguities are handled by calling this method.
- Specified by:
handlesAmbiguity
in interfacePacking
- Returns:
- true if ambiguities are stored, false otherwise
-