public class JavaMapImporter extends MapImporter
level.dat
files and based on BlockBasedPlatformProvider
s.MapImporter.ReadOnlyOption
Modifier and Type | Field and Description |
---|---|
static java.util.Map<java.lang.String,Terrain> |
TERRAIN_MAPPING |
Constructor and Description |
---|
JavaMapImporter(Platform platform,
TileFactory tileFactory,
java.io.File levelDatFile,
java.util.Set<MinecraftCoords> chunksToSkip,
MapImporter.ReadOnlyOption readOnlyOption,
java.util.Set<java.lang.Integer> dimensionsToImport) |
Modifier and Type | Method and Description |
---|---|
World2 |
doImport(org.pepsoft.util.ProgressReceiver progressReceiver)
Import the map (optionally reporting progress to the specified progress receiver) and returning it as a
World2 object. |
java.lang.String |
getWarnings()
Get the warnings generated by the import, or
null if there were none. |
protected World2 |
importWorld(JavaLevel level) |
doImport
public static final java.util.Map<java.lang.String,Terrain> TERRAIN_MAPPING
public JavaMapImporter(Platform platform, TileFactory tileFactory, java.io.File levelDatFile, java.util.Set<MinecraftCoords> chunksToSkip, MapImporter.ReadOnlyOption readOnlyOption, java.util.Set<java.lang.Integer> dimensionsToImport)
public World2 doImport(org.pepsoft.util.ProgressReceiver progressReceiver) throws java.io.IOException, org.pepsoft.util.ProgressReceiver.OperationCancelled
MapImporter
World2
object.doImport
in class MapImporter
progressReceiver
- The progress receiver to which to report progress. May be null
, indicating that
no progress need be reported.World2
object.java.io.IOException
- If an I/O error occurred importing the map.ProgressReceiver.OperationCancelled
- If the progress receiver threw an
ProgressReceiver.OperationCancelled
exception.public java.lang.String getWarnings()
MapImporter
null
if there were none. Multiple warnings should be on
separate lines separated by line separators (\n
).getWarnings
in class MapImporter
null
if there were none.