Record Class ArtifactMetadata
java.lang.Object
java.lang.Record
net.fabricmc.loom.configuration.mods.ArtifactMetadata
public record ArtifactMetadata(boolean isFabricMod, ArtifactMetadata.RemapRequirements remapRequirements, @Nullable InstallerData installerData, ArtifactMetadata.MixinRemapType mixinRemapType, List<String> knownIdyBsms)
extends Record
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic enumstatic enum -
Constructor Summary
ConstructorsConstructorDescriptionArtifactMetadata(boolean isFabricMod, ArtifactMetadata.RemapRequirements remapRequirements, @Nullable InstallerData installerData, ArtifactMetadata.MixinRemapType mixinRemapType, List<String> knownIdyBsms) Creates an instance of aArtifactMetadatarecord class. -
Method Summary
Modifier and TypeMethodDescriptionstatic ArtifactMetadatacreate(ArtifactRef artifact, String currentLoomVersion, ArtifactMetadata.MixinRemapType defaultMixinRemapType) static ArtifactMetadatacreate(@Nullable org.gradle.api.Project project, ArtifactRef artifact, String currentLoomVersion, ModPlatform platform, ArtifactMetadata.MixinRemapType defaultMixinRemapType) final booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.@Nullable InstallerDataReturns the value of theinstallerDatarecord component.booleanReturns the value of theisFabricModrecord component.Returns the value of theknownIdyBsmsrecord component.Returns the value of themixinRemapTyperecord component.Returns the value of theremapRequirementsrecord component.booleanfinal StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
ArtifactMetadata
public ArtifactMetadata(boolean isFabricMod, ArtifactMetadata.RemapRequirements remapRequirements, @Nullable InstallerData installerData, ArtifactMetadata.MixinRemapType mixinRemapType, List<String> knownIdyBsms) Creates an instance of aArtifactMetadatarecord class.- Parameters:
isFabricMod- the value for theisFabricModrecord componentremapRequirements- the value for theremapRequirementsrecord componentinstallerData- the value for theinstallerDatarecord componentmixinRemapType- the value for themixinRemapTyperecord componentknownIdyBsms- the value for theknownIdyBsmsrecord component
-
-
Method Details
-
create
@VisibleForTesting public static ArtifactMetadata create(ArtifactRef artifact, String currentLoomVersion, ArtifactMetadata.MixinRemapType defaultMixinRemapType) throws IOException - Throws:
IOException
-
create
public static ArtifactMetadata create(@Nullable org.gradle.api.Project project, ArtifactRef artifact, String currentLoomVersion, ModPlatform platform, ArtifactMetadata.MixinRemapType defaultMixinRemapType) throws IOException - Throws:
IOException
-
shouldRemap
public boolean shouldRemap() -
toString
Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components. -
hashCode
public final int hashCode()Returns a hash code value for this object. The value is derived from the hash code of each of the record components. -
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. Reference components are compared withObjects::equals(Object,Object); primitive components are compared with '=='. -
isFabricMod
public boolean isFabricMod()Returns the value of theisFabricModrecord component.- Returns:
- the value of the
isFabricModrecord component
-
remapRequirements
Returns the value of theremapRequirementsrecord component.- Returns:
- the value of the
remapRequirementsrecord component
-
installerData
Returns the value of theinstallerDatarecord component.- Returns:
- the value of the
installerDatarecord component
-
mixinRemapType
Returns the value of themixinRemapTyperecord component.- Returns:
- the value of the
mixinRemapTyperecord component
-
knownIdyBsms
Returns the value of theknownIdyBsmsrecord component.- Returns:
- the value of the
knownIdyBsmsrecord component
-