/** * Map an HDT file into memory to use it. This method does not load the whole file into memory, * it lets the OS to handle memory pages as desired. Therefore it uses less memory but can be slower * for querying because it needs to load those blocks from disk. * NOTE: Use this method to go through all elements. If you plan to do queries, use mapIndexedHDT() instead. * @param hdtFileName * @return * @throws IOException */ public static HDT mapHDT(String hdtFileName) throws IOException { return HDTManager.getInstance().doMapHDT(hdtFileName, null); }
/** * Map an HDT file into memory to use it. This method does not load the whole file into memory, * it lets the OS to handle memory pages as desired. Therefore it uses less memory but can be slower * for querying because it needs to load those blocks from disk. * NOTE: Use this method to go through all elements. If you plan to do queries, use mapIndexedHDT() instead. * @param hdtFileName * @param listener Listener to get notified of loading progress. Can be null if no notifications needed. * @return * @throws IOException */ public static HDT mapHDT(String hdtFileName, ProgressListener listener) throws IOException { return HDTManager.getInstance().doMapHDT(hdtFileName, listener); }