public interface WorldExporter
Platform
.
Created by Pepijn on 12-2-2017.Modifier and Type | Method and Description |
---|---|
java.util.Map<java.lang.Integer,ChunkFactory.Stats> |
export(java.io.File baseDir,
java.lang.String name,
java.io.File backupDir,
org.pepsoft.util.ProgressReceiver progressReceiver)
Export the world previously configured for export by the call to
PlatformProvider.getExporter(World2, WorldExportSettings)
to a directory with the specified name in the specified directory. |
World2 |
getWorld()
Get the world that is being or has been exported.
|
java.io.File |
selectBackupDir(java.io.File worldDir)
Indicate into which directory the existing map, if any, will be backed up that is going to be exported into
worldDir . |
default java.io.File |
selectBackupDir(java.io.File baseDir,
java.lang.String name)
Indicate into which directory the existing map, if any, would be backed up if the specified world would be
exported into the specified base directory.
|
World2 getWorld()
default java.io.File selectBackupDir(java.io.File baseDir, java.lang.String name) throws java.io.IOException
baseDir
- The base directory in which the map directory would be created into which the world would be
exported.name
- The map name to which the world is being exported.java.io.IOException
- If an I/O error occurs while determining the backup directory.java.io.File selectBackupDir(java.io.File worldDir) throws java.io.IOException
worldDir
.worldDir
- The map directory into which the world would be exported.java.io.IOException
- If an I/O error occurs while determining the backup directory.java.util.Map<java.lang.Integer,ChunkFactory.Stats> export(java.io.File baseDir, java.lang.String name, java.io.File backupDir, org.pepsoft.util.ProgressReceiver progressReceiver) throws java.io.IOException, org.pepsoft.util.ProgressReceiver.OperationCancelled
PlatformProvider.getExporter(World2, WorldExportSettings)
to a directory with the specified name in the specified directory.baseDir
- The directory in which to create the map directory.name
- The name to give the map directory.backupDir
- The directory to which to backup the existing map
directory, if any.progressReceiver
- An optional progress receiver to which to report
the progress of the export. May be null
.java.io.IOException
- If an I/O error occurs while exporting the world.ProgressReceiver.OperationCancelled
- If the progress receiver has
thrown an ProgressReceiver.OperationCancelled
exception, or the
user has in some other manner indicated that the export should be
aborted.