public class KeybindText extends BaseText
Text.Serializerclass_5348.StyledVisitor<T>, class_5348.Visitor<T>| Modifier and Type | Field and Description |
|---|---|
private String |
key |
private Supplier<Text> |
translated |
private static Function<String,Supplier<Text>> |
translator |
field_25309, field_25310| Constructor and Description |
|---|
KeybindText(String key) |
| Modifier and Type | Method and Description |
|---|---|
KeybindText |
copy()
Copies the text itself, excluding the styles or siblings.
|
boolean |
equals(Object obj) |
String |
getKey() |
private Text |
getTranslated() |
static void |
setTranslator(Function<String,Supplier<Text>> translator) |
String |
toString() |
<T> Optional<T> |
visitSelf(class_5348.StyledVisitor<T> visitor,
Style style)
Visits the text itself.
|
<T> Optional<T> |
visitSelf(class_5348.Visitor<T> visitor)
Visits the text itself.
|
append, asString, getSiblings, getStyle, hashCode, setStyle, shallowCopyclone, finalize, getClass, notify, notifyAll, wait, wait, waitappend, fillStyle, formatted, formatted, styledasTruncatedString, getString, visit, visitmethod_29430, method_29431, method_29432, method_29433private final String key
public KeybindText(String key)
@Environment(value=CLIENT) public static void setTranslator(Function<String,Supplier<Text>> translator)
private Text getTranslated()
public <T> Optional<T> visitSelf(class_5348.Visitor<T> visitor)
visitor - the visitorclass_5348.visit(Visitor)@Environment(value=CLIENT) public <T> Optional<T> visitSelf(class_5348.StyledVisitor<T> visitor, Style style)
visitor - the visitorstyle - the current styleclass_5348.visit(StyledVisitor, Style)public KeybindText copy()
Textpublic String getKey()