Class ViaFacet.ProtocolBased<V>
java.lang.Object
net.kyori.adventure.platform.facet.FacetBase<V>
net.kyori.adventure.platform.viaversion.ViaFacet<V>
net.kyori.adventure.platform.viaversion.ViaFacet.ProtocolBased<V>
- All Implemented Interfaces:
net.kyori.adventure.platform.facet.Facet<V>,net.kyori.adventure.platform.facet.Facet.Message<V,String>
- Direct Known Subclasses:
ViaFacet.ActionBarTitle,ViaFacet.BossBar,ViaFacet.Chat,ViaFacet.TabList,ViaFacet.Title
-
Nested Class Summary
Nested classes/interfaces inherited from class net.kyori.adventure.platform.viaversion.ViaFacet
ViaFacet.ActionBar<V>, ViaFacet.ActionBarTitle<V>, ViaFacet.BossBar<V>, ViaFacet.Chat<V>, ViaFacet.ProtocolBased<V>, ViaFacet.TabList<V>, ViaFacet.Title<V>Nested classes/interfaces inherited from interface net.kyori.adventure.platform.facet.Facet
net.kyori.adventure.platform.facet.Facet.Book<V,M, B>, net.kyori.adventure.platform.facet.Facet.BossBarEntity<V, P>, net.kyori.adventure.platform.facet.Facet.BossBarPacket<V>, net.kyori.adventure.platform.facet.Facet.ChatPacket<V, M>, net.kyori.adventure.platform.facet.Facet.EntitySound<V, M>, net.kyori.adventure.platform.facet.Facet.FakeEntity<V, P>, net.kyori.adventure.platform.facet.Facet.Message<V, M>, net.kyori.adventure.platform.facet.Facet.Pointers<V>, net.kyori.adventure.platform.facet.Facet.Position<V, P>, net.kyori.adventure.platform.facet.Facet.Sound<V, P>, net.kyori.adventure.platform.facet.Facet.TitlePacket<V, M, C, T> -
Field Summary
Fields inherited from class net.kyori.adventure.platform.facet.FacetBase
viewerClassFields inherited from interface net.kyori.adventure.platform.facet.Facet.Message
PROTOCOL_HEX_COLOR, PROTOCOL_JSON, VERSION_HEX_COLOR -
Constructor Summary
ConstructorsModifierConstructorDescriptionprotectedProtocolBased(@NotNull String fromProtocol, @NotNull String toProtocol, String minProtocol, @NotNull String packetName, @NotNull Class<? extends V> viewerClass, @NotNull Function<V, com.viaversion.viaversion.api.connection.UserConnection> connectionFunction, boolean rewriteLegacyTranslations) -
Method Summary
Modifier and TypeMethodDescriptioncom.viaversion.viaversion.api.protocol.packet.PacketWrappercreatePacket(V viewer) boolean@NotNull com.viaversion.viaversion.libs.gson.JsonElement@NotNull com.viaversion.viaversion.libs.gson.JsonElementvoidsendPacket(@NotNull com.viaversion.viaversion.api.protocol.packet.PacketWrapper packet) Methods inherited from class net.kyori.adventure.platform.viaversion.ViaFacet
createMessage, findConnection, findProtocol, isApplicable
-
Constructor Details
-
ProtocolBased
protected ProtocolBased(@NotNull @NotNull String fromProtocol, @NotNull @NotNull String toProtocol, String minProtocol, @NotNull @NotNull String packetName, @NotNull @NotNull Class<? extends V> viewerClass, @NotNull @NotNull Function<V, com.viaversion.viaversion.api.connection.UserConnection> connectionFunction, boolean rewriteLegacyTranslations)
-
-
Method Details
-
isSupported
public boolean isSupported()- Specified by:
isSupportedin interfacenet.kyori.adventure.platform.facet.Facet<V>- Overrides:
isSupportedin classViaFacet<V>
-
createPacket
-
sendPacket
public void sendPacket(@NotNull @NotNull com.viaversion.viaversion.api.protocol.packet.PacketWrapper packet) -
parse
@NotNull public @NotNull com.viaversion.viaversion.libs.gson.JsonElement parse(@NotNull @NotNull String message) -
parse
-