public class BAMEncoderV1_0 extends BAMEncoder
Constructor and Description |
---|
BAMEncoderV1_0(Bundle outputBundle,
ReadsEncoderOptions readsEncoderOptions)
Create a V1.0 BAM encoder for the given output bundle.
|
Modifier and Type | Method and Description |
---|---|
void |
close()
Close any resources associated with this decoder.
|
HtsVersion |
getVersion()
Get the version of the file format supported by this encoder.
|
void |
setHeader(SAMFileHeader samFileHeader)
Set the file format header for this decoder, of type
H . |
void |
write(SAMRecord record)
Write a single record to the underlying output.
|
getDisplayName, getFileFormat, getOutputBundle, getReadsEncoderOptions
public BAMEncoderV1_0(Bundle outputBundle, ReadsEncoderOptions readsEncoderOptions)
BundleResourceType.ALIGNED_READS
(to find a decoder for a bundle,
see ReadsResolver
).outputBundle
- bundle to encodereadsEncoderOptions
- options to usepublic HtsVersion getVersion()
HtsEncoder
public void setHeader(SAMFileHeader samFileHeader)
HtsEncoder
H
. HtsEncoder.setHeader(HtsHeader)
must be
called before HtsEncoder.write(HtsRecord)
can be called.samFileHeader
- to usepublic void write(SAMRecord record)
HtsEncoder
HtsEncoder.write(HtsRecord)
may only called after
HtsEncoder.setHeader(HtsHeader)
has been called.record
- record to writepublic void close()
HtsEncoder