Package net.draycia.carbon.api.util
Interface ChatComponentRenderer
- All Known Subinterfaces:
ChatChannel,KeyedRenderer
- Functional Interface:
- This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.
@FunctionalInterface
@DefaultQualifier(org.checkerframework.checker.nullness.qual.NonNull.class)
public interface ChatComponentRenderer
Renderer used to construct chat components on a per-player basis.
- Since:
- 2.0.0
-
Method Summary
-
Method Details
-
render
Component render(CarbonPlayer sender, Audience recipient, Component message, Component originalMessage) Renders a Component for the specified recipient.- Parameters:
sender- the player that sent the messagerecipient- a recipient of the message. may be a player, console, or other Audience implementationsmessage- the message being sentoriginalMessage- the original message that was sent- Returns:
- the component to be shown to the recipient, or empty if the recipient should not receive the message
- Since:
- 2.0.0
-