Package com.ldtteam.structurize.storage
Class StructurePackMeta
java.lang.Object
com.ldtteam.structurize.storage.StructurePackMeta
Wrapper that contains all the info of the structure pack.
-
Constructor Summary
ConstructorsConstructorDescriptionStructurePackMeta(com.google.gson.JsonObject json, Path rootPath, String owner) Initialize the pack from json. -
Method Summary
Modifier and TypeMethodDescriptionGet the list of authors.getDesc()Getter for the pack description.Get the icon path string.Get the list of mods that were used in this schematic.getName()getNormalizedSubPath(String subPath) Get the normalized sub path from this pack.getOwner()Get the owning mod of place of this pack.intGet the pack format.getPath()Get the structure pack root path.getSubPath(Path subPath) Get the sub path from this pack.doubleGet the pack version.booleanCheck if the structure pack is immutable.voidsetImmutable(boolean immutable) Set the immutability param.
-
Constructor Details
-
StructurePackMeta
Initialize the pack from json.- Parameters:
json- the json to use.
-
-
Method Details
-
getName
-
setImmutable
public void setImmutable(boolean immutable) Set the immutability param.- Parameters:
immutable- true if immutable, else false.
-
isImmutable
public boolean isImmutable()Check if the structure pack is immutable.- Returns:
- true if so.
-
getPackFormat
public int getPackFormat()Get the pack format.- Returns:
- the format version.
-
getVersion
public double getVersion()Get the pack version.- Returns:
- the pack version.
-
getModList
Get the list of mods that were used in this schematic.- Returns:
- the list of mod ids.
-
getPath
Get the structure pack root path. -
getIconPath
Get the icon path string.- Returns:
- the name of the icon.
-
getDesc
Getter for the pack description.- Returns:
- the desc string.
-
getAuthors
Get the list of authors.- Returns:
- list of names.
-
getOwner
Get the owning mod of place of this pack.- Returns:
- the pack.
-
getSubPath
Get the sub path from this pack.- Parameters:
subPath- the path we're in.- Returns:
- the relative sub path.
-
getNormalizedSubPath
Get the normalized sub path from this pack.- Parameters:
subPath- the path we're in.- Returns:
- the relative sub path.
-