public final class CommonInfo extends Object implements Serializable
Modifier and Type | Field and Description |
---|---|
static double |
NO_LOG10_PERROR |
static long |
serialVersionUID |
Constructor and Description |
---|
CommonInfo(String name,
double log10PError,
Set<String> filters,
Map<String,Object> attributes) |
Modifier and Type | Method and Description |
---|---|
void |
addFilter(String filter) |
void |
addFilters(Collection<String> filters) |
void |
clearAttributes() |
boolean |
filtersWereApplied() |
Object |
getAttribute(String key) |
Object |
getAttribute(String key,
Object defaultValue) |
boolean |
getAttributeAsBoolean(String key,
boolean defaultValue) |
double |
getAttributeAsDouble(String key,
double defaultValue) |
int |
getAttributeAsInt(String key,
int defaultValue) |
List<Object> |
getAttributeAsList(String key)
returns the value as an empty list if the key was not found,
as a java.util.List if the value is a List or an Array,
as a Collections.singletonList if there is only one value
|
String |
getAttributeAsString(String key,
String defaultValue) |
Map<String,Object> |
getAttributes() |
Set<String> |
getFilters() |
Set<String> |
getFiltersMaybeNull() |
double |
getLog10PError() |
String |
getName() |
int |
getNumAttributes() |
double |
getPhredScaledQual()
Floating-point arithmetic allows signed zeros such as +0.0 and -0.0.
|
boolean |
hasAttribute(String key) |
boolean |
hasLog10PError() |
boolean |
isFiltered() |
boolean |
isNotFiltered() |
void |
putAttribute(String key,
Object value) |
void |
putAttribute(String key,
Object value,
boolean allowOverwrites) |
void |
putAttributes(Map<String,?> map) |
void |
removeAttribute(String key) |
void |
setAttributes(Map<String,?> map) |
void |
setLog10PError(double log10PError) |
void |
setName(String name)
Sets the name
|
public static final long serialVersionUID
public static final double NO_LOG10_PERROR
public String getName()
public void setName(String name)
name
- the name associated with this informationpublic boolean filtersWereApplied()
public boolean isFiltered()
public boolean isNotFiltered()
public void addFilter(String filter)
public void addFilters(Collection<String> filters)
public boolean hasLog10PError()
public double getLog10PError()
public double getPhredScaledQual()
public void setLog10PError(double log10PError)
public void clearAttributes()
public void removeAttribute(String key)
public boolean hasAttribute(String key)
public int getNumAttributes()
public Object getAttribute(String key)
key
- the attribute keypublic List<Object> getAttributeAsList(String key)
public int getAttributeAsInt(String key, int defaultValue)
public double getAttributeAsDouble(String key, double defaultValue)
public boolean getAttributeAsBoolean(String key, boolean defaultValue)