Package net.mcreator.workspace
Class WorkspaceFolderManager
java.lang.Object
net.mcreator.workspace.WorkspaceFolderManager
-
Method Summary
Modifier and TypeMethodDescriptionFile[]getArmorTextureFilesForName(String armorTextureName) getPathInWorkspace(File file) Attempts to locate the provided file inside workspace folder and return its path relative to this folder.static FilegetTextureFile(String textureIdentifier, TextureType section) This method gets a PNG texture file depending on the desired type.getTexturesFolder(TextureType section) getTexturesList(TextureType section) booleanisFileInWorkspace(File file) Checks if the provided file is contained in the workspace folder.booleanisFileInWorkspace(File file, boolean silent) Checks if the provided file is contained in the workspace folder.voidremoveStructure(String name)
-
Method Details
-
getSuggestedWorkspaceFoldersRoot
-
getWorkspaceFolder
-
isFileInWorkspace
Checks if the provided file is contained in the workspace folder.- Parameters:
file- The file to check.- Returns:
- True if the provided file is inside the workspace folder.
-
isFileInWorkspace
Checks if the provided file is contained in the workspace folder.- Parameters:
file- The file to check.silent- Determines whether non-presence of input file in the workspace should be logged or not.- Returns:
- True if the provided file is inside the workspace folder.
-
getPathInWorkspace
Attempts to locate the provided file inside workspace folder and return its path relative to this folder.- Parameters:
file- The input file.- Returns:
- File path relative to workspace folder or its absolute path if not found in the workspace.
-
getTextureFile
This method gets a PNG texture file depending on the desired type.
- Parameters:
textureIdentifier-This is the name without the file extension of the texture file.
section-This
TextureTypedefines which path, defined by each generator, MCreator will search the texture file.- Returns:
A PNG
File
-
getStructureList
-
getArmorTextureFilesForName
-
getTexturesList
- Parameters:
section-The
TextureTypewe want to get the folder, defined by each generator.- Returns:
A list containing all texture files found in the
TextureTypeprovided.
-
removeStructure
-
getTexturesFolder
- Parameters:
section-The
TextureTypewe want to get the folder, defined by each generator.- Returns:
The folder storing texture files of the given
TextureType.
-
getStructuresDir
-
getSoundsDir
-
getClientRunDir
-
getServerRunDir
-
getModsDir
-
getModElementsDir
-
getModelsDir
-
getModelAnimationsDir
-
getWorkspaceCacheDir
-
getModElementPicturesCacheDir
-
getWorkspaceBackupsCacheDir
-