 |
Gridarta Editor
|
Go to the documentation of this file.
20 package net.sf.gridarta.gui.mapfiles;
23 import java.util.Arrays;
33 import org.jetbrains.annotations.NotNull;
34 import org.jetbrains.annotations.Nullable;
80 public Loader(@NotNull
final ErrorView errorView, @NotNull
final MapFolderTree<G, A, R> mapFolderTree, @NotNull
final MapReaderFactory<G, A> mapReaderFactory, @NotNull
final MapManager<G, A, R> pickmapManager, @NotNull
final MapViewsManager<G, A, R> mapViewsManager) {
93 if (mapFolder !=
null) {
108 final File dir = parent ==
null ? baseDir :
new File(parent.getDir(), folderName);
110 final File[]
files = dir.listFiles();
132 for (
final File file :
files) {
139 }
else if (file.isDirectory()) {
140 if (!file.getName().startsWith(
".")) {
142 if (result ==
null && tmp !=
null && tmp.
getPickmaps() > 0) {
149 return mapFolder.
getPickmaps() > 0 ? mapFolder : result;
void addWarning(@NotNull final ErrorViewCategory category)
Adds a warning message.
A MapManager manages all opened maps.
Loader for pickmaps from a directory.
Base package of all Gridarta classes.
Loader(@NotNull final ErrorView errorView, @NotNull final MapFolderTree< G, A, R > mapFolderTree, @NotNull final MapReaderFactory< G, A > mapReaderFactory, @NotNull final MapManager< G, A, R > pickmapManager, @NotNull final MapViewsManager< G, A, R > mapViewsManager)
Creates a new instance.
Standard Edition Runtime Environment README Import and export control rules on cryptographic software vary from country to country The Java Cryptography Java provides two different sets of cryptographic policy files
A factory for creating MapReader instances.
Interface for classes displaying error messages.
synchronized void addMapFolder(@NotNull final MapFolder< G, A, R > mapFolder)
Adds a map folder to this model.
Reflects a game object (object on a map).
final MapViewsManager< G, A, R > mapViewsManager
The MapViewsManager.
final MapReaderFactory< G, A > mapReaderFactory
The MapReaderFactory for loading map files.
Graphical User Interface of Gridarta.
MapFolder< G, A, R > load(@Nullable final MapFolder< G, A, R > parent, @NotNull final String folderName)
Loads all pickmap files from a directory and its sub-directories.
GameObjects are the objects based on Archetypes found on maps.
final MapManager< G, A, R > pickmapManager
The MapManager for loading pickmaps.
Convenience class for adding messages to a ErrorView instance using a fixed category name.
String getName()
Returns the name.
Indicates that a folder or pickmap name is invalid.
Defines possible error categories for ErrorView instances.
Interface for MapArchObjects.
PickmapState< G, A, R > addPickmap(@NotNull final String name, @NotNull final MapReaderFactory< G, A > mapReaderFactory, @NotNull final MapManager< G, A, R > pickmapManager)
Adds a new PickmapState to this folder.
final MapFolderTree< G, A, R > mapFolderTree
The model to add the loaded pickmaps to.
Reading and writing of maps, handling of paths.
Indicates that a folder name is not unique.
Base classes for rendering maps.
final ErrorView errorView
The ErrorView for reporting errors.
File getBaseDir()
Returns the base directory for creating new map folders.
void load()
Loads all pickmap files from a directory and its sub-directories.
int getPickmaps()
Returns the number of pickmaps in this folder.
synchronized void setActiveMapFolder(@NotNull final MapFolder< G, A, R > mapFolder)
Sets the active map folder.
Stores all existing MapViews.