Record Class TrueTypeGlyphProviderDefinition
java.lang.Object
java.lang.Record
net.minecraft.client.gui.font.providers.TrueTypeGlyphProviderDefinition
- All Implemented Interfaces:
GlyphProviderDefinition
public record TrueTypeGlyphProviderDefinition(ResourceLocation location, float size, float oversample, TrueTypeGlyphProviderDefinition.Shift shift, String skip)
extends Record
implements GlyphProviderDefinition
-
Nested Class Summary
Nested ClassesNested classes/interfaces inherited from interface net.minecraft.client.gui.font.providers.GlyphProviderDefinition
GlyphProviderDefinition.Conditional, GlyphProviderDefinition.Loader, GlyphProviderDefinition.Reference -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final com.mojang.serialization.MapCodec<TrueTypeGlyphProviderDefinition> private final ResourceLocationThe field for thelocationrecord component.private final floatThe field for theoversamplerecord component.private final TrueTypeGlyphProviderDefinition.ShiftThe field for theshiftrecord component.private final floatThe field for thesizerecord component.private final StringThe field for theskiprecord component.private static final com.mojang.serialization.Codec<String> Fields inherited from interface net.minecraft.client.gui.font.providers.GlyphProviderDefinition
MAP_CODEC -
Constructor Summary
ConstructorsConstructorDescriptionTrueTypeGlyphProviderDefinition(ResourceLocation location, float size, float oversample, TrueTypeGlyphProviderDefinition.Shift shift, String skip) Creates an instance of aTrueTypeGlyphProviderDefinitionrecord class. -
Method Summary
Modifier and TypeMethodDescriptionfinal booleanIndicates whether some other object is "equal to" this one.final inthashCode()Returns a hash code value for this object.private GlyphProviderload(ResourceManager resourceManager) location()Returns the value of thelocationrecord component.floatReturns the value of theoversamplerecord component.shift()Returns the value of theshiftrecord component.floatsize()Returns the value of thesizerecord component.skip()Returns the value of theskiprecord component.final StringtoString()Returns a string representation of this record class.type()com.mojang.datafixers.util.Either<GlyphProviderDefinition.Loader, GlyphProviderDefinition.Reference> unpack()
-
Field Details
-
location
The field for thelocationrecord component. -
size
private final float sizeThe field for thesizerecord component. -
oversample
private final float oversampleThe field for theoversamplerecord component. -
shift
The field for theshiftrecord component. -
skip
The field for theskiprecord component. -
SKIP_LIST_CODEC
-
CODEC
-
-
Constructor Details
-
TrueTypeGlyphProviderDefinition
public TrueTypeGlyphProviderDefinition(ResourceLocation location, float size, float oversample, TrueTypeGlyphProviderDefinition.Shift shift, String skip) Creates an instance of aTrueTypeGlyphProviderDefinitionrecord class.- Parameters:
location- the value for thelocationrecord componentsize- the value for thesizerecord componentoversample- the value for theoversamplerecord componentshift- the value for theshiftrecord componentskip- the value for theskiprecord component
-
-
Method Details
-
type
- Specified by:
typein interfaceGlyphProviderDefinition
-
unpack
public com.mojang.datafixers.util.Either<GlyphProviderDefinition.Loader,GlyphProviderDefinition.Reference> unpack()- Specified by:
unpackin interfaceGlyphProviderDefinition
-
load
- Throws:
IOException
-
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 '=='. -
location
Returns the value of thelocationrecord component.- Returns:
- the value of the
locationrecord component
-
size
public float size()Returns the value of thesizerecord component.- Returns:
- the value of the
sizerecord component
-
oversample
public float oversample()Returns the value of theoversamplerecord component.- Returns:
- the value of the
oversamplerecord component
-
shift
Returns the value of theshiftrecord component.- Returns:
- the value of the
shiftrecord component
-
skip
Returns the value of theskiprecord component.- Returns:
- the value of the
skiprecord component
-