T
- the type of Feature that this FeatureInput file contains (eg., VariantContext, BEDFeature, etc.)public final class FeatureInput<T extends htsjdk.tribble.Feature> extends GATKPath implements java.io.Serializable
GATKTool.addFeatureInputsAfterInitialization(String, String, Class, int)
in order to register the FeatureInput with the engine.
FeatureInputs can be assigned logical names on the command line using the syntax:
--argument_name:logical_name feature_file
These logical names can then be retrieved by the tool at runtime via getName()
Furthermore, a list of comma-separated key=value pairs may be provided as follows:
--argument_name:logical_name,key1=value1,key2=value2 feature_file
the string value provided for a given key can be retrieved via getAttribute(String)
. Keys must be unique.Modifier and Type | Field and Description |
---|---|
static java.lang.String |
FEATURE_ARGUMENT_TAG_DELIMITER
Delimiter between the logical name and the file name in the --argument_name logical_name:feature_file syntax
|
protected static org.apache.logging.log4j.Logger |
logger |
HDFS_SCHEME
Constructor and Description |
---|
FeatureInput(GATKPath gatkPath)
Construct a FeatureInput from a GATKPath argument value.
|
FeatureInput(GATKPath gatkPath,
java.lang.String name)
Construct a FeatureInput from a GATKPath argument value.
|
FeatureInput(java.lang.String rawInputSpecifier,
java.lang.String name,
java.util.Map<java.lang.String,java.lang.String> keyValueMap)
Construct a FeatureInput from raw components: name, key value pairs and the file.
|
Modifier and Type | Method and Description |
---|---|
boolean |
equals(java.lang.Object other)
Test FeatureInputs for equality
|
java.lang.String |
getAttribute(java.lang.String key)
Gets the value for the given key associated with this Feature source or
null
if no value is associated with a given key. |
java.lang.Class<htsjdk.tribble.FeatureCodec<T,?>> |
getFeatureCodecClass() |
java.lang.String |
getFeaturePath()
Gets the file backing this source of Features
|
java.lang.String |
getName()
Gets the logical name of this Feature source.
|
int |
hashCode()
FeatureInputs will be hashed by the engine, so make an effort to produce a reasonable hash code
|
boolean |
hasUserSuppliedName() |
void |
setFeatureCodecClass(java.lang.Class<htsjdk.tribble.FeatureCodec<T,?>> featureCodecClass)
Remember the FeatureCodec class for this input the first time it is discovered so we can bypass dynamic codec
discovery when multiple FeatureDataSources are created for the same input.
|
java.lang.String |
toString()
Returns a String representation of this FeatureInput.
|
getInputStream, getOutputStream, getTag, getTagAttributes, isHadoopURL, setTag, setTagAttributes, toPath
getCachedPath, getRawInputString, getToPathFailureReason, getURI, getURIString, hasFileSystemProvider, isPath, setCachedPath
protected static final org.apache.logging.log4j.Logger logger
public static final java.lang.String FEATURE_ARGUMENT_TAG_DELIMITER
public FeatureInput(GATKPath gatkPath)
gatkPath
- an existing GATKPath objectpublic FeatureInput(GATKPath gatkPath, java.lang.String name)
gatkPath
- an existing GATKPath objectname
- the tag name for this feature inputpublic FeatureInput(java.lang.String rawInputSpecifier, java.lang.String name, java.util.Map<java.lang.String,java.lang.String> keyValueMap)
public void setFeatureCodecClass(java.lang.Class<htsjdk.tribble.FeatureCodec<T,?>> featureCodecClass)
public java.lang.Class<htsjdk.tribble.FeatureCodec<T,?>> getFeatureCodecClass()
null
.public java.lang.String getAttribute(java.lang.String key)
null
if no value is associated with a given key.java.lang.IllegalArgumentException
- if the key is null
.public java.lang.String getName()
public boolean hasUserSuppliedName()
public java.lang.String getFeaturePath()
public int hashCode()
public boolean equals(java.lang.Object other)
public java.lang.String toString()