Package dev.architectury.loom.metadata
Class QuiltModJson
java.lang.Object
dev.architectury.loom.metadata.QuiltModJson
- All Implemented Interfaces:
JsonBackedModMetadataFile,ModMetadataFile
-
Field Summary
Fields -
Method Summary
Modifier and TypeMethodDescriptionbooleangetAccessTransformers(ModPlatform platform) Returns the paths to the access transformer files of this mod, or an empty set if absent.Returns the paths to the access widener file of this mod, or an empty set if absent.@Nullable com.google.gson.JsonElementgetCustomValue(String key) Gets a custom value from this mod metadata file.Returns "quilt.mod.json".@Nullable StringgetId()Returns the mod ID in this mod metadata file, ornullif absent.getIds()Returns all mod IDs in this mod metadata file.getInjectedInterfaces(@Nullable String modId) Returns the injected interface data in this mod metadata file.com.google.gson.JsonObjectgetJson()Returns the backing JSON object of this mod metadata file.Returns a list of the mixin configs declared in this mod metadata file.inthashCode()static QuiltModJsonof(byte[] utf8) static QuiltModJsonof(com.google.gson.JsonObject json) static QuiltModJsonstatic QuiltModJsonstatic QuiltModJson
-
Field Details
-
FILE_NAME
- See Also:
-
JSON5_FILE_NAME
- See Also:
-
-
Method Details
-
of
-
of
-
of
- Throws:
IOException
-
of
- Throws:
IOException
-
of
-
getJson
public com.google.gson.JsonObject getJson()Description copied from interface:JsonBackedModMetadataFileReturns the backing JSON object of this mod metadata file..- Specified by:
getJsonin interfaceJsonBackedModMetadataFile- Returns:
- the backing JSON object of this mod metadata file
-
getId
Description copied from interface:ModMetadataFileReturns the mod ID in this mod metadata file, ornullif absent..- Specified by:
getIdin interfaceModMetadataFile- Returns:
- the mod ID in this mod metadata file, or
nullif absent
-
getAccessWideners
Description copied from interface:ModMetadataFileReturns the paths to the access widener file of this mod, or an empty set if absent..- Specified by:
getAccessWidenersin interfaceModMetadataFile- Returns:
- the paths to the access widener file of this mod, or an empty set if absent
-
getAccessTransformers
Description copied from interface:ModMetadataFileReturns the paths to the access transformer files of this mod, or an empty set if absent..- Specified by:
getAccessTransformersin interfaceModMetadataFile- Parameters:
platform- the platform to run the query on- Returns:
- the paths to the access transformer files of this mod, or an empty set if absent
-
getInjectedInterfaces
public List<InterfaceInjectionProcessor.InjectedInterface> getInjectedInterfaces(@Nullable String modId) Description copied from interface:ModMetadataFileReturns the injected interface data in this mod metadata file..- Specified by:
getInjectedInterfacesin interfaceModMetadataFile- Parameters:
modId- the mod ID to use as a fallback ifModMetadataFile.getId()returnsnull- Returns:
- the injected interface data in this mod metadata file
-
getMixinConfigs
Description copied from interface:ModMetadataFileReturns a list of the mixin configs declared in this mod metadata file..- Specified by:
getMixinConfigsin interfaceModMetadataFile- Returns:
- a list of the mixin configs declared in this mod metadata file
-
getFileName
Returns "quilt.mod.json"..- Specified by:
getFileNamein interfaceModMetadataFile- Returns:
- "quilt.mod.json"
-
getCustomValue
Description copied from interface:JsonBackedModMetadataFileGets a custom value from this mod metadata file.If the format doesn't support custom values, returns
null.- Specified by:
getCustomValuein interfaceJsonBackedModMetadataFile- Parameters:
key- the key of the custom value- Returns:
- the custom value, or
nullif not found
-
equals
-
hashCode
public int hashCode() -
getIds
Description copied from interface:ModMetadataFileReturns all mod IDs in this mod metadata file..- Specified by:
getIdsin interfaceModMetadataFile- Returns:
- all mod IDs in this mod metadata file
-