import htsjdk.samtools.util.CloseableIterator;
import htsjdk.variant.variantcontext.VariantContext;
import htsjdk.variant.vcf.VCFFileReader;
+import htsjdk.variant.vcf.VCFHeader;
import java.io.Closeable;
import java.io.File;
/**
* Queries for records overlapping the region specified. Note that this method
* requires a VCF file with an associated index. If no index exists a
- * TribbleException will be thrown.
+ * TribbleException will be thrown. Client code should call close() on the
+ * iterator when finished with it.
*
* @param chrom
* the chromosome to query
{
return reader == null ? null : reader.query(chrom, start, end);
}
+
+ /**
+ * Returns an object that models the VCF file headers
+ *
+ * @return
+ */
+ public VCFHeader getFileHeader()
+ {
+ return reader == null ? null : reader.getFileHeader();
+ }
}