public void readHeader ( ReadBuffer readBuffer , long fileSize ) throws IOException { RequiredFields . readMagicByte ( readBuffer ) ; RequiredFields . readRemainingHeader ( readBuffer ) ; MapFileInfoBuilder mapFileInfoBuilder = new MapFileInfoBuilder ( ) ; RequiredFields . readFileVersion ( readBuffer , mapFileInfoBuilder ) ; RequiredFields . readFileSize ( readBuffer , fileSize , mapFileInfoBuilder ) ; RequiredFields . readMapDate ( readBuffer , mapFileInfoBuilder ) ; RequiredFields . readBoundingBox ( readBuffer , mapFileInfoBuilder ) ; RequiredFields . readTilePixelSize ( readBuffer , mapFileInfoBuilder ) ; RequiredFields . readProjectionName ( readBuffer , mapFileInfoBuilder ) ; OptionalFields . readOptionalFields ( readBuffer , mapFileInfoBuilder ) ; RequiredFields . readPoiTags ( readBuffer , mapFileInfoBuilder ) ; RequiredFields . readWayTags ( readBuffer , mapFileInfoBuilder ) ; readSubFileParameters ( readBuffer , fileSize , mapFileInfoBuilder ) ; this . mapFileInfo = mapFileInfoBuilder . build ( ) ; }
Reads and validates the header block from the map file .