Interface MessageCommandSender

All Superinterfaces:
net.kyori.adventure.audience.Audience, CommandSender, Permissible, net.kyori.adventure.pointer.Pointered, ServerOperator
All Known Implementing Classes:
BufferedCommandSender, TimingsReportListener

@Deprecated(forRemoval=true) public interface MessageCommandSender extends CommandSender
Deprecated, for removal: This API element is subject to removal in a future version.
Timings will be removed in the future
For when all you care about is just messaging
  • Nested Class Summary

    Nested classes/interfaces inherited from interface org.bukkit.command.CommandSender

    CommandSender.Spigot
  • Method Summary

    Modifier and Type
    Method
    Description
    default @NotNull PermissionAttachment
    addAttachment(@NotNull Plugin plugin)
    Deprecated, for removal: This API element is subject to removal in a future version.
    Adds a new empty PermissionAttachment to this object
    default @NotNull PermissionAttachment
    addAttachment(@NotNull Plugin plugin, int ticks)
    Deprecated, for removal: This API element is subject to removal in a future version.
    Temporarily adds a new empty PermissionAttachment to this object
    default @NotNull PermissionAttachment
    addAttachment(@NotNull Plugin plugin, @NotNull String name, boolean value)
    Deprecated, for removal: This API element is subject to removal in a future version.
    Adds a new PermissionAttachment with a single permission by name and value
    default @NotNull PermissionAttachment
    addAttachment(@NotNull Plugin plugin, @NotNull String name, boolean value, int ticks)
    Deprecated, for removal: This API element is subject to removal in a future version.
    Temporarily adds a new PermissionAttachment with a single permission by name and value
    default @NotNull Set<PermissionAttachmentInfo>
    Deprecated, for removal: This API element is subject to removal in a future version.
    Gets a set containing all of the permissions currently in effect by this object
    default @NotNull String
    Deprecated, for removal: This API element is subject to removal in a future version.
    Gets the name of this command sender
    default @NotNull Server
    Deprecated, for removal: This API element is subject to removal in a future version.
    Returns the server instance that this command is running on
    default boolean
    hasPermission(@NotNull String name)
    Deprecated, for removal: This API element is subject to removal in a future version.
    Gets the value of the specified permission, if set.
    default boolean
    hasPermission(@NotNull Permission perm)
    Deprecated, for removal: This API element is subject to removal in a future version.
    Gets the value of the specified permission, if set.
    default boolean
    Deprecated, for removal: This API element is subject to removal in a future version.
    Checks if this object is a server operator
    default boolean
    isPermissionSet(@NotNull String name)
    Deprecated, for removal: This API element is subject to removal in a future version.
    Checks if this object contains an override for the specified permission, by fully qualified name
    default boolean
    isPermissionSet(@NotNull Permission perm)
    Deprecated, for removal: This API element is subject to removal in a future version.
    Checks if this object contains an override for the specified Permission
    default @NotNull net.kyori.adventure.text.Component
    Deprecated, for removal: This API element is subject to removal in a future version.
    Gets the name of this command sender
    default void
    Deprecated, for removal: This API element is subject to removal in a future version.
    Recalculates the permissions for this object, if the attachments have changed values.
    default void
    Deprecated, for removal: This API element is subject to removal in a future version.
    Removes the given PermissionAttachment from this object
    default void
    sendMessage(@NotNull String @NotNull [] messages)
    Deprecated, for removal: This API element is subject to removal in a future version.
    Sends this sender multiple messages
    default void
    sendMessage(@Nullable UUID sender, @NotNull String message)
    Deprecated, for removal: This API element is subject to removal in a future version.
    Sends this sender a message
    default void
    sendMessage(@Nullable UUID sender, @NotNull String @NotNull [] messages)
    Deprecated, for removal: This API element is subject to removal in a future version.
    Sends this sender multiple messages
    default void
    setOp(boolean value)
    Deprecated, for removal: This API element is subject to removal in a future version.
    Sets the operator status of this object
    default @NotNull CommandSender.Spigot
    Deprecated, for removal: This API element is subject to removal in a future version.
     

    Methods inherited from interface net.kyori.adventure.audience.Audience

    clearResourcePacks, clearTitle, closeDialog, deleteMessage, deleteMessage, filterAudience, forEachAudience, hideBossBar, openBook, openBook, playSound, playSound, playSound, removeResourcePacks, removeResourcePacks, removeResourcePacks, removeResourcePacks, removeResourcePacks, resetTitle, sendActionBar, sendActionBar, sendMessage, sendMessage, sendMessage, sendMessage, sendMessage, sendMessage, sendMessage, sendMessage, sendMessage, sendMessage, sendMessage, sendMessage, sendMessage, sendMessage, sendPlayerListFooter, sendPlayerListFooter, sendPlayerListHeader, sendPlayerListHeader, sendPlayerListHeaderAndFooter, sendPlayerListHeaderAndFooter, sendResourcePacks, sendResourcePacks, sendResourcePacks, sendTitlePart, showBossBar, showDialog, showTitle, stopSound, stopSound

    Methods inherited from interface org.bukkit.permissions.Permissible

    permissionValue, permissionValue

    Methods inherited from interface net.kyori.adventure.pointer.Pointered

    get, getOrDefault, getOrDefaultFrom, pointers
  • Method Details

    • sendMessage

      default void sendMessage(@NotNull @NotNull String @NotNull [] messages)
      Deprecated, for removal: This API element is subject to removal in a future version.
      Description copied from interface: CommandSender
      Sends this sender multiple messages
      Specified by:
      sendMessage in interface CommandSender
      Parameters:
      messages - An array of messages to be displayed
      See Also:
    • sendMessage

      default void sendMessage(@Nullable @Nullable UUID sender, @NotNull @NotNull String message)
      Deprecated, for removal: This API element is subject to removal in a future version.
      Description copied from interface: CommandSender
      Sends this sender a message
      Specified by:
      sendMessage in interface CommandSender
      Parameters:
      sender - The sender of this message
      message - Message to be displayed
      See Also:
      • Audience.sendMessage(net.kyori.adventure.identity.Identified, net.kyori.adventure.text.Component)
    • sendMessage

      default void sendMessage(@Nullable @Nullable UUID sender, @NotNull @NotNull String @NotNull [] messages)
      Deprecated, for removal: This API element is subject to removal in a future version.
      Description copied from interface: CommandSender
      Sends this sender multiple messages
      Specified by:
      sendMessage in interface CommandSender
      Parameters:
      sender - The sender of this message
      messages - An array of messages to be displayed
      See Also:
      • Audience.sendMessage(net.kyori.adventure.identity.Identified, net.kyori.adventure.text.Component)
    • getServer

      @NotNull default @NotNull Server getServer()
      Deprecated, for removal: This API element is subject to removal in a future version.
      Description copied from interface: CommandSender
      Returns the server instance that this command is running on
      Specified by:
      getServer in interface CommandSender
      Returns:
      Server instance
    • name

      default @NotNull net.kyori.adventure.text.Component name()
      Deprecated, for removal: This API element is subject to removal in a future version.
      Description copied from interface: CommandSender
      Gets the name of this command sender
      Specified by:
      name in interface CommandSender
      Returns:
      Name of the sender
    • getName

      @NotNull default @NotNull String getName()
      Deprecated, for removal: This API element is subject to removal in a future version.
      Description copied from interface: CommandSender
      Gets the name of this command sender
      Specified by:
      getName in interface CommandSender
      Returns:
      Name of the sender
    • isOp

      default boolean isOp()
      Deprecated, for removal: This API element is subject to removal in a future version.
      Description copied from interface: ServerOperator
      Checks if this object is a server operator
      Specified by:
      isOp in interface ServerOperator
      Returns:
      true if this is an operator, otherwise false
    • setOp

      default void setOp(boolean value)
      Deprecated, for removal: This API element is subject to removal in a future version.
      Description copied from interface: ServerOperator
      Sets the operator status of this object
      Specified by:
      setOp in interface ServerOperator
      Parameters:
      value - New operator value
    • isPermissionSet

      default boolean isPermissionSet(@NotNull @NotNull String name)
      Deprecated, for removal: This API element is subject to removal in a future version.
      Description copied from interface: Permissible
      Checks if this object contains an override for the specified permission, by fully qualified name
      Specified by:
      isPermissionSet in interface Permissible
      Parameters:
      name - Name of the permission
      Returns:
      true if the permission is set, otherwise false
    • isPermissionSet

      default boolean isPermissionSet(@NotNull @NotNull Permission perm)
      Deprecated, for removal: This API element is subject to removal in a future version.
      Description copied from interface: Permissible
      Checks if this object contains an override for the specified Permission
      Specified by:
      isPermissionSet in interface Permissible
      Parameters:
      perm - Permission to check
      Returns:
      true if the permission is set, otherwise false
    • hasPermission

      default boolean hasPermission(@NotNull @NotNull String name)
      Deprecated, for removal: This API element is subject to removal in a future version.
      Description copied from interface: Permissible
      Gets the value of the specified permission, if set.

      If a permission override is not set on this object, the default value of the permission will be returned.

      Specified by:
      hasPermission in interface Permissible
      Parameters:
      name - Name of the permission
      Returns:
      Value of the permission
    • hasPermission

      default boolean hasPermission(@NotNull @NotNull Permission perm)
      Deprecated, for removal: This API element is subject to removal in a future version.
      Description copied from interface: Permissible
      Gets the value of the specified permission, if set.

      If a permission override is not set on this object, the default value of the permission will be returned

      Specified by:
      hasPermission in interface Permissible
      Parameters:
      perm - Permission to get
      Returns:
      Value of the permission
    • addAttachment

      @NotNull default @NotNull PermissionAttachment addAttachment(@NotNull @NotNull Plugin plugin, @NotNull @NotNull String name, boolean value)
      Deprecated, for removal: This API element is subject to removal in a future version.
      Description copied from interface: Permissible
      Adds a new PermissionAttachment with a single permission by name and value
      Specified by:
      addAttachment in interface Permissible
      Parameters:
      plugin - Plugin responsible for this attachment, may not be null or disabled
      name - Name of the permission to attach
      value - Value of the permission
      Returns:
      The PermissionAttachment that was just created
    • addAttachment

      @NotNull default @NotNull PermissionAttachment addAttachment(@NotNull @NotNull Plugin plugin)
      Deprecated, for removal: This API element is subject to removal in a future version.
      Description copied from interface: Permissible
      Adds a new empty PermissionAttachment to this object
      Specified by:
      addAttachment in interface Permissible
      Parameters:
      plugin - Plugin responsible for this attachment, may not be null or disabled
      Returns:
      The PermissionAttachment that was just created
    • addAttachment

      @NotNull default @NotNull PermissionAttachment addAttachment(@NotNull @NotNull Plugin plugin, @NotNull @NotNull String name, boolean value, int ticks)
      Deprecated, for removal: This API element is subject to removal in a future version.
      Description copied from interface: Permissible
      Temporarily adds a new PermissionAttachment with a single permission by name and value
      Specified by:
      addAttachment in interface Permissible
      Parameters:
      plugin - Plugin responsible for this attachment, may not be null or disabled
      name - Name of the permission to attach
      value - Value of the permission
      ticks - Amount of ticks to automatically remove this attachment after
      Returns:
      The PermissionAttachment that was just created
    • addAttachment

      @NotNull default @NotNull PermissionAttachment addAttachment(@NotNull @NotNull Plugin plugin, int ticks)
      Deprecated, for removal: This API element is subject to removal in a future version.
      Description copied from interface: Permissible
      Temporarily adds a new empty PermissionAttachment to this object
      Specified by:
      addAttachment in interface Permissible
      Parameters:
      plugin - Plugin responsible for this attachment, may not be null or disabled
      ticks - Amount of ticks to automatically remove this attachment after
      Returns:
      The PermissionAttachment that was just created
    • removeAttachment

      default void removeAttachment(@NotNull @NotNull PermissionAttachment attachment)
      Deprecated, for removal: This API element is subject to removal in a future version.
      Description copied from interface: Permissible
      Removes the given PermissionAttachment from this object
      Specified by:
      removeAttachment in interface Permissible
      Parameters:
      attachment - Attachment to remove
    • recalculatePermissions

      default void recalculatePermissions()
      Deprecated, for removal: This API element is subject to removal in a future version.
      Description copied from interface: Permissible
      Recalculates the permissions for this object, if the attachments have changed values.

      This should very rarely need to be called from a plugin.

      Specified by:
      recalculatePermissions in interface Permissible
    • getEffectivePermissions

      @NotNull default @NotNull Set<PermissionAttachmentInfo> getEffectivePermissions()
      Deprecated, for removal: This API element is subject to removal in a future version.
      Description copied from interface: Permissible
      Gets a set containing all of the permissions currently in effect by this object
      Specified by:
      getEffectivePermissions in interface Permissible
      Returns:
      Set of currently effective permissions
    • spigot

      @NotNull default @NotNull CommandSender.Spigot spigot()
      Deprecated, for removal: This API element is subject to removal in a future version.
      Specified by:
      spigot in interface CommandSender