Record Class FilteredText
java.lang.Object
java.lang.Record
net.minecraft.server.network.FilteredText
-
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final FilteredTextprivate final FilterMaskThe field for themaskrecord component.private final StringThe field for therawrecord component. -
Constructor Summary
ConstructorsConstructorDescriptionFilteredText(String raw, FilterMask mask) Creates an instance of aFilteredTextrecord class. -
Method Summary
Modifier and TypeMethodDescriptionfinal booleanIndicates whether some other object is "equal to" this one.@Nullable Stringfiltered()static FilteredTextfullyFiltered(String message) final inthashCode()Returns a hash code value for this object.booleanmask()Returns the value of themaskrecord component.static FilteredTextpassThrough(String message) raw()Returns the value of therawrecord component.final StringtoString()Returns a string representation of this record class.
-
Field Details
-
raw
The field for therawrecord component. -
mask
The field for themaskrecord component. -
EMPTY
-
-
Constructor Details
-
FilteredText
Creates an instance of aFilteredTextrecord class.- Parameters:
raw- the value for therawrecord componentmask- the value for themaskrecord component
-
-
Method Details
-
passThrough
-
fullyFiltered
-
filtered
-
filteredOrEmpty
-
isFiltered
public boolean isFiltered() -
toString
-
hashCode
-
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. All components in this record class are compared withObjects::equals(Object,Object). -
raw
Returns the value of therawrecord component.- Returns:
- the value of the
rawrecord component
-
mask
Returns the value of themaskrecord component.- Returns:
- the value of the
maskrecord component
-