Package htsjdk.variant.vcf
Class VCFHeaderLine
- java.lang.Object
-
- htsjdk.variant.vcf.VCFHeaderLine
-
- All Implemented Interfaces:
Serializable
,Comparable
- Direct Known Subclasses:
VCFCompoundHeaderLine
,VCFSimpleHeaderLine
public class VCFHeaderLine extends Object implements Comparable, Serializable
- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description protected static boolean
ALLOW_UNBOUND_DESCRIPTIONS
static long
serialVersionUID
protected static String
UNBOUND_DESCRIPTION
-
Constructor Summary
Constructors Constructor Description VCFHeaderLine(String key, String value)
create a VCF header line
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description int
compareTo(Object other)
boolean
equals(Object o)
String
getKey()
Get the keyString
getValue()
Get the valueint
hashCode()
static boolean
isHeaderLine(String line)
boolean
shouldBeAddedToDictionary()
By default the header lines won't be added to the dictionary, unless this method will be override (for example in FORMAT, INFO or FILTER header lines)String
toString()
protected String
toStringEncoding()
Should be overloaded in sub classes to do subclass specificstatic String
toStringEncoding(Map<String,? extends Object> keyValues)
create a string of a mapping pair for the target VCF version
-
-
-
Field Detail
-
serialVersionUID
public static final long serialVersionUID
- See Also:
- Constant Field Values
-
ALLOW_UNBOUND_DESCRIPTIONS
protected static final boolean ALLOW_UNBOUND_DESCRIPTIONS
- See Also:
- Constant Field Values
-
UNBOUND_DESCRIPTION
protected static final String UNBOUND_DESCRIPTION
- See Also:
- Constant Field Values
-
-
Method Detail
-
getKey
public String getKey()
Get the key- Returns:
- the key
-
getValue
public String getValue()
Get the value- Returns:
- the value
-
shouldBeAddedToDictionary
public boolean shouldBeAddedToDictionary()
By default the header lines won't be added to the dictionary, unless this method will be override (for example in FORMAT, INFO or FILTER header lines)- Returns:
- false
-
toStringEncoding
protected String toStringEncoding()
Should be overloaded in sub classes to do subclass specific- Returns:
- the string encoding
-
compareTo
public int compareTo(Object other)
- Specified by:
compareTo
in interfaceComparable
-
isHeaderLine
public static boolean isHeaderLine(String line)
- Parameters:
line
- the line- Returns:
- true if the line is a VCF meta data line, or false if it is not
-
-