Package net.minecraft.resource
Class ResourcePackProfile
java.lang.Object
net.minecraft.resource.ResourcePackProfile
- All Implemented Interfaces:
AutoCloseable
public class ResourcePackProfile extends Object implements AutoCloseable
-
Nested Class Summary
Nested Classes Modifier and Type Class Description static interfaceResourcePackProfile.Factorystatic classResourcePackProfile.InsertionPosition -
Field Summary
Fields Modifier and Type Field Description private booleanalwaysEnabledprivate ResourcePackCompatibilitycompatibilityprivate Textdescriptionprivate TextdisplayNameprivate static LoggerLOGGERprivate Stringnameprivate Supplier<ResourcePack>packGetterprivate booleanpinnedprivate ResourcePackProfile.InsertionPositionpositionprivate ResourcePackSourcesource -
Constructor Summary
Constructors Constructor Description ResourcePackProfile(String name, boolean alwaysEnabled, Supplier<ResourcePack> packFactory, Text displayName, Text description, ResourcePackCompatibility compatibility, ResourcePackProfile.InsertionPosition direction, boolean pinned, ResourcePackSource source)ResourcePackProfile(String name, Text displayName, boolean alwaysEnabled, Supplier<ResourcePack> packFactory, PackResourceMetadata metadata, ResourceType type, ResourcePackProfile.InsertionPosition direction, ResourcePackSource source) -
Method Summary
Modifier and Type Method Description voidclose()ResourcePackcreateResourcePack()booleanequals(Object o)ResourcePackCompatibilitygetCompatibility()TextgetDescription()TextgetDisplayName()TextgetInformationText(boolean enabled)ResourcePackProfile.InsertionPositiongetInitialPosition()StringgetName()ResourcePackSourcegetSource()inthashCode()booleanisAlwaysEnabled()booleanisPinned()static ResourcePackProfileof(String name, boolean alwaysEnabled, Supplier<ResourcePack> packFactory, ResourcePackProfile.Factory containerFactory, ResourcePackProfile.InsertionPosition insertionPosition, ResourcePackSource resourcePackSource)
-
Field Details
-
LOGGER
-
name
-
packGetter
-
displayName
-
description
-
compatibility
-
position
-
alwaysEnabled
private final boolean alwaysEnabled -
pinned
private final boolean pinned -
source
-
-
Constructor Details
-
ResourcePackProfile
public ResourcePackProfile(String name, boolean alwaysEnabled, Supplier<ResourcePack> packFactory, Text displayName, Text description, ResourcePackCompatibility compatibility, ResourcePackProfile.InsertionPosition direction, boolean pinned, ResourcePackSource source) -
ResourcePackProfile
public ResourcePackProfile(String name, Text displayName, boolean alwaysEnabled, Supplier<ResourcePack> packFactory, PackResourceMetadata metadata, ResourceType type, ResourcePackProfile.InsertionPosition direction, ResourcePackSource source)
-
-
Method Details
-
of
@Nullable public static ResourcePackProfile of(String name, boolean alwaysEnabled, Supplier<ResourcePack> packFactory, ResourcePackProfile.Factory containerFactory, ResourcePackProfile.InsertionPosition insertionPosition, ResourcePackSource resourcePackSource) -
getDisplayName
-
getDescription
-
getInformationText
-
getCompatibility
-
createResourcePack
-
getName
-
isAlwaysEnabled
public boolean isAlwaysEnabled() -
isPinned
public boolean isPinned() -
getInitialPosition
-
getSource
-
equals
-
hashCode
public int hashCode() -
close
public void close()- Specified by:
closein interfaceAutoCloseable
-