Interface DataMetadata
-
public interface DataMetadata
This interface define metadata of data objects.- Since:
- 2.0
- Author:
- Laurent Jourdren
-
-
Field Summary
Fields Modifier and Type Field Description static String
FASTQ_FORMAT_KEY
static String
PAIRED_END_KEY
static String
SAMPLE_ID_KEY
static String
SAMPLE_NAME_KEY
static String
SAMPLE_NUMBER_KEY
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description void
clear()
Clear the entries of the object.boolean
containsKey(String key)
Test if a key exists.String
get(String key)
Get the value of metadata entry.fr.ens.biologie.genomique.kenetre.bio.FastqFormat
getFastqFormat()
Get the FastqFormat.fr.ens.biologie.genomique.kenetre.bio.FastqFormat
getFastqFormat(fr.ens.biologie.genomique.kenetre.bio.FastqFormat defaultValue)
Get the FastqFormat.String
getSampleId()
Get the sample id related to the data.String
getSampleName()
Get the sample name related to the data.int
getSampleNumber()
Get the sample number related to the data.boolean
isPairedEnd()
Test if the data is paired end data.Set<String>
keySet()
Get the keys of the entries.boolean
removeKey(String key)
Remove a entry.void
set(DataMetadata metadata)
The the entries of the metadata with the entries of another metadata object.void
set(String key, String value)
Set a metadata entry.void
setFastqFormat(fr.ens.biologie.genomique.kenetre.bio.FastqFormat fastqFormat)
Set the FASTQ format of the data.void
setPairedEnd(boolean pairedEnd)
Set single-end/paired-end data type.void
setSampleId(String sampleId)
Set the sample id related to the datavoid
setSampleName(String sampleName)
Set the sample name related to the data.void
setSampleNumber(int sampleNumber)
Set the sample number related to the data
-
-
-
Field Detail
-
PAIRED_END_KEY
static final String PAIRED_END_KEY
- See Also:
- Constant Field Values
-
FASTQ_FORMAT_KEY
static final String FASTQ_FORMAT_KEY
- See Also:
- Constant Field Values
-
SAMPLE_ID_KEY
static final String SAMPLE_ID_KEY
- See Also:
- Constant Field Values
-
SAMPLE_NAME_KEY
static final String SAMPLE_NAME_KEY
- See Also:
- Constant Field Values
-
SAMPLE_NUMBER_KEY
static final String SAMPLE_NUMBER_KEY
- See Also:
- Constant Field Values
-
-
Method Detail
-
get
String get(String key)
Get the value of metadata entry.- Parameters:
key
- the key- Returns:
- the value related to key or null if the key does not exists
-
set
void set(String key, String value)
Set a metadata entry.- Parameters:
key
- the keyvalue
- the value
-
containsKey
boolean containsKey(String key)
Test if a key exists.- Parameters:
key
- the key to test- Returns:
- true if the key exists
-
removeKey
boolean removeKey(String key)
Remove a entry.- Parameters:
key
- the key of the entry to remove- Returns:
- true if the entry has been removed
-
set
void set(DataMetadata metadata)
The the entries of the metadata with the entries of another metadata object.- Parameters:
metadata
- the entries to add
-
clear
void clear()
Clear the entries of the object.
-
keySet
Set<String> keySet()
Get the keys of the entries.- Returns:
- a set with the keys of the entries
-
isPairedEnd
boolean isPairedEnd()
Test if the data is paired end data.- Returns:
- true if the data is paired end data
-
setPairedEnd
void setPairedEnd(boolean pairedEnd)
Set single-end/paired-end data type.- Parameters:
pairedEnd
- true if data is paired-end data
-
getFastqFormat
fr.ens.biologie.genomique.kenetre.bio.FastqFormat getFastqFormat()
Get the FastqFormat. If value not set, the default format is fastq-sanger.- Returns:
- the fastq format
-
getFastqFormat
fr.ens.biologie.genomique.kenetre.bio.FastqFormat getFastqFormat(fr.ens.biologie.genomique.kenetre.bio.FastqFormat defaultValue)
Get the FastqFormat.- Parameters:
defaultValue
- the default value- Returns:
- the fastq format
-
setFastqFormat
void setFastqFormat(fr.ens.biologie.genomique.kenetre.bio.FastqFormat fastqFormat)
Set the FASTQ format of the data.- Parameters:
fastqFormat
- the FASTQ format
-
getSampleName
String getSampleName()
Get the sample name related to the data.- Returns:
- a String with the sample name related to the data
-
setSampleName
void setSampleName(String sampleName)
Set the sample name related to the data.- Parameters:
sampleName
- the sample name
-
getSampleId
String getSampleId()
Get the sample id related to the data.- Returns:
- the sample id or null if the value is not set
-
setSampleId
void setSampleId(String sampleId)
Set the sample id related to the data- Parameters:
sampleId
- the sample id
-
getSampleNumber
int getSampleNumber()
Get the sample number related to the data.- Returns:
- the sample number or -1 if the value is not set
-
setSampleNumber
void setSampleNumber(int sampleNumber)
Set the sample number related to the data- Parameters:
sampleNumber
- the sample number
-
-