/** * * @return Returns a stream of the file without the header. So you can directly start reading the data of the map. * @throws IOException */ public final InputStream getMapDataStream() throws IOException { InputStream inputStream = getMapInputStream(file); MapFileHeader.readFromStream(inputStream); return inputStream; }
public static MapFileHeader loadHeader(IListedMap file) throws MapLoadException { try (InputStream stream = getMapInputStream(file)) { return MapFileHeader.readFromStream(stream); } catch (IOException e) { throw new MapLoadException("Error during header request for map " + file + " exception: ", e); } }