diff --git a/src/main/java/htsjdk/tribble/index/IndexFactory.java b/src/main/java/htsjdk/tribble/index/IndexFactory.java index 99ce636691..e48acc0a25 100644 --- a/src/main/java/htsjdk/tribble/index/IndexFactory.java +++ b/src/main/java/htsjdk/tribble/index/IndexFactory.java @@ -343,6 +343,7 @@ public static Index createDynamicInd return createDynamicIndex(inputPath, codec, IndexBalanceApproach.FOR_SEEK_TIME); } + /** * Create a index of the specified type with default binning parameters * @@ -356,6 +357,34 @@ public static Index createIndex(fina return createIndex(IOUtil.toPath(inputFile), codec, type, null); } + /** + * Create a index of the specified type with default binning parameters + * + * @param inputhPath the input file to load features from + * @param codec the codec to use for decoding records + * @param type the type of index to create + */ + public static Index createIndex(final Path inputhPath, + final FeatureCodec codec, + final IndexType type) { + return createIndex(inputhPath, codec, type, null); + } + + /** + * Create an index of the specified type with default binning parameters + * + * @param inputFile the input File to load features from + * @param codec the codec to use for decoding records + * @param type the type of index to create + * @param sequenceDictionary May be null, but if present may reduce memory footprint for tabix index creation + */ + public static Index createIndex(final File inputFile, + final FeatureCodec codec, + final IndexType type, + final SAMSequenceDictionary sequenceDictionary) { + return createIndex(IOUtil.toPath(inputFile), codec, type, sequenceDictionary); + } + /** * Create an index of the specified type with default binning parameters *