Package htsjdk.tribble.annotation
Enum Class Strand
- All Implemented Interfaces:
Serializable
,Comparable<Strand>
,Constable
Enum for strand, which can be encoded as a string
-
Nested Class Summary
Nested classes/interfaces inherited from class java.lang.Enum
Enum.EnumDesc<E extends Enum<E>>
-
Enum Constant Summary
Enum Constants -
Field Summary
Fields -
Method Summary
Modifier and TypeMethodDescriptionstatic Strand
decode
(char ch) Returns theStrand
that achar
value represents.static Strand
encode()
Returns a string representation of thisStrand
char
Returns a single char encoding of thisStrand
.static Strand
Deprecated.toString()
static Strand
Returns the enum constant of this class with the specified name.static Strand[]
values()
Returns an array containing the constants of this enum class, in the order they are declared.
-
Enum Constant Details
-
POSITIVE
Represents the positive or forward strand. -
NEGATIVE
Represents the negative or reverse strand. -
NONE
Denotes that a strand designation is not applicable or is unknown.
-
-
Field Details
-
Method Details
-
values
Returns an array containing the constants of this enum class, in the order they are declared.- Returns:
- an array containing the constants of this enum class, in the order they are declared
-
valueOf
Returns the enum constant of this class with the specified name. The string must match exactly an identifier used to declare an enum constant in this class. (Extraneous whitespace characters are not permitted.)- Parameters:
name
- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException
- if this enum class has no constant with the specified nameNullPointerException
- if the argument is null
-
toStrand
Deprecated.please usedecode(char)
instead.provide a way to take an encoding string, and produce a Strand- Parameters:
encoding
- the encoding string- Returns:
- a Strand object, if an appropriate one cannot be located an IllegalArg exception
-
decode
Returns theStrand
that achar
value represents.- Parameters:
ch
- the char encoding for a Strand.- Returns:
- never
null
, a value so thatdecode(c).encodeAsChar() == c
orNONE
if the encoding char is not recognized.
-
decode
- Parameters:
encoding
- the strand string representation.- Returns:
- never
null
, a value so thatdecode(s).encode().equals(s)
, orNONE
if the encoding string is not recognized.
-
encode
Returns a string representation of thisStrand
- Returns:
- never
null
, a value so thatdecode(encode(X)) == X
.
-
encodeAsChar
public char encodeAsChar()Returns a single char encoding of thisStrand
.- Returns:
- a value so that
decode(encodeAsChar(X)) == X
.
-
toString
-
decode(char)
instead.