public class SortingVariantContextWriter extends Object
| Modifier and Type | Field and Description |
|---|---|
protected static int |
BEFORE_MOST_UPSTREAM_LOC |
protected Integer |
mostUpstreamWritableLoc |
| Constructor and Description |
|---|
SortingVariantContextWriter(VariantContextWriter innerWriter,
int maxCachingStartDistance) |
SortingVariantContextWriter(VariantContextWriter innerWriter,
int maxCachingStartDistance,
boolean takeOwnershipOfInner)
create a local-sorting VCF writer, given an inner VCF writer to write to
|
| Modifier and Type | Method and Description |
|---|---|
void |
add(VariantContext vc)
add a record to the file
|
boolean |
checkError() |
void |
close()
attempt to close the VCF file; we need to flush the queue first
|
protected void |
emitSafeRecords() |
protected void |
noteCurrentRecord(VariantContext vc) |
String |
toString()
Gets a string representation of this object.
|
void |
writeHeader(VCFHeader header) |
protected Integer mostUpstreamWritableLoc
protected static final int BEFORE_MOST_UPSTREAM_LOC
public SortingVariantContextWriter(VariantContextWriter innerWriter, int maxCachingStartDistance, boolean takeOwnershipOfInner)
innerWriter - the VCFWriter to write tomaxCachingStartDistance - the maximum start distance between records that we'll cachetakeOwnershipOfInner - Should this Writer close innerWriter when it's done with itpublic SortingVariantContextWriter(VariantContextWriter innerWriter, int maxCachingStartDistance)
protected void noteCurrentRecord(VariantContext vc)
public boolean checkError()
public void writeHeader(VCFHeader header)
writeHeader in interface VariantContextWriterpublic void close()
close in interface VariantContextWriterclose in interface Closeableclose in interface AutoCloseablepublic void add(VariantContext vc)
add in interface VariantContextWritervc - the Variant Context objectpublic String toString()
protected void emitSafeRecords()