Class AdventureSerializer
java.lang.Object
com.github.retrooper.packetevents.util.adventure.AdventureSerializer
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic StringasVanilla(net.kyori.adventure.text.Component component) static net.kyori.adventure.text.ComponentfromLegacyFormat(String legacyMessage) static net.kyori.adventure.text.Componentstatic net.kyori.adventure.text.serializer.gson.GsonComponentSerializerstatic net.kyori.adventure.text.serializer.legacy.LegacyComponentSerializerDeprecated.static net.kyori.adventure.text.serializer.legacy.LegacyComponentSerializerstatic AdventureNBTSerializerstatic net.kyori.adventure.text.ComponentparseComponent(String json) static net.kyori.adventure.text.ComponentparseJsonTree(com.google.gson.JsonElement json) static StringtoJson(net.kyori.adventure.text.Component component) static com.google.gson.JsonElementtoJsonTree(net.kyori.adventure.text.Component component) static StringtoLegacyFormat(net.kyori.adventure.text.Component component) static NBTtoNbt(net.kyori.adventure.text.Component component)
-
Constructor Details
-
AdventureSerializer
public AdventureSerializer()
-
-
Method Details
-
getGsonSerializer
public static net.kyori.adventure.text.serializer.gson.GsonComponentSerializer getGsonSerializer() -
getLegacyGsonSerializer
@Deprecated public static net.kyori.adventure.text.serializer.legacy.LegacyComponentSerializer getLegacyGsonSerializer()Deprecated. -
getLegacySerializer
public static net.kyori.adventure.text.serializer.legacy.LegacyComponentSerializer getLegacySerializer() -
getNBTSerializer
-
asVanilla
-
fromLegacyFormat
-
toLegacyFormat
-
parseComponent
-
parseJsonTree
public static net.kyori.adventure.text.Component parseJsonTree(com.google.gson.JsonElement json) -
toJson
-
toJsonTree
public static com.google.gson.JsonElement toJsonTree(net.kyori.adventure.text.Component component) -
fromNbt
-
toNbt
-