Class SAMEncoderV1_0
java.lang.Object
htsjdk.beta.codecs.reads.sam.SAMEncoder
htsjdk.beta.codecs.reads.sam.samV1_0.SAMEncoderV1_0
- All Implemented Interfaces:
HtsEncoder<SAMFileHeader,
,SAMRecord> ReadsEncoder
,Closeable
,AutoCloseable
SAM v1.0 encoder.
-
Constructor Summary
ConstructorDescriptionSAMEncoderV1_0
(Bundle outputBundle, ReadsEncoderOptions readsEncoderOptions) Create a V1.0 SAM encoder for the given output bundle. -
Method Summary
Modifier and TypeMethodDescriptionvoid
close()
Close any resources associated with this decoder.Get the version of the file format supported by this encoder.void
setHeader
(SAMFileHeader samFileHeader) Set the file format header for this decoder, of typeHtsEncoder
.void
Write a single record to the underlying output.Methods inherited from class htsjdk.beta.codecs.reads.sam.SAMEncoder
getDisplayName, getFileFormat, getOutputBundle, getReadsEncoderOptions
-
Constructor Details
-
SAMEncoderV1_0
Create a V1.0 SAM encoder for the given output bundle. The primary resource in the bundle must have content typeBundleResourceType.ALIGNED_READS
(to find a decoder for a bundle, seeReadsResolver
).- Parameters:
outputBundle
- bundle to encodereadsEncoderOptions
- options to use
-
-
Method Details
-
getVersion
Description copied from interface:HtsEncoder
Get the version of the file format supported by this encoder. -
setHeader
Description copied from interface:HtsEncoder
Set the file format header for this decoder, of typeHtsEncoder
.HtsEncoder.setHeader(HtsHeader)
must be called beforeHtsEncoder.write(HtsRecord)
can be called.- Parameters:
samFileHeader
- to use
-
write
Description copied from interface:HtsEncoder
Write a single record to the underlying output.HtsEncoder.write(HtsRecord)
may only called afterHtsEncoder.setHeader(HtsHeader)
has been called.- Parameters:
record
- record to write
-
close
public void close()Description copied from interface:HtsEncoder
Close any resources associated with this decoder.
-