Package net.kyori.text.adapter.bukkit
Interface SpigotTextAdapter
public interface SpigotTextAdapter
An adapter for converting text
Components to Spigot (BungeeCord) objects.
This class is an extension of TextAdapter, since the plain Bukkit API does not include
the BungeeCord Chat API.
-
Method Summary
Static Methods Modifier and Type Method Description static @NonNull net.md_5.bungee.api.chat.BaseComponent[]toBungeeCord(@NonNull net.kyori.text.Component component)Convertscomponentto theBaseComponentformat used by Spigot (BungeeCord).
-
Method Details
-
toBungeeCord
static @NonNull net.md_5.bungee.api.chat.BaseComponent[] toBungeeCord(@NonNull net.kyori.text.Component component)Convertscomponentto theBaseComponentformat used by Spigot (BungeeCord).The adapter makes no guarantees about the underlying structure/type of the components. i.e. is it not guaranteed that a
TextComponentwill map to aTextComponent.The
sendComponentmethods should be used instead of this method when possible.- Parameters:
component- the component- Returns:
- the Text representation of the component
-