Interface Actor

All Superinterfaces:
Identifiable, SessionOwner, Subject
All Known Subinterfaces:
Player
All Known Implementing Classes:
AbstractCommandBlockActor, AbstractNonPlayerActor, AbstractPlayerActor

public interface Actor extends Identifiable, SessionOwner, Subject
An object that can perform actions in WorldEdit.
  • Method Summary

    Modifier and Type
    Method
    Description
    boolean
    Returns true if the actor can destroy bedrock.
    void
    Send a CUI event.
    default String
    Gets the display name of the actor.
    Get the locale of this actor.
    Get the name of the actor.
    boolean
    Return whether this actor is a player.
    openFileOpenDialog(String[] extensions)
    Open a file open dialog.
    openFileSaveDialog(String[] extensions)
    Open a file save dialog.
    void
    print(com.sk89q.worldedit.util.formatting.text.Component component)
    Print a Component.
    void
    Deprecated.
    Use component-based functions (printInfo)
    default void
    printDebug(com.sk89q.worldedit.util.formatting.text.Component component)
    Print a WorldEdit message.
    void
    Deprecated.
    Use component-based functions (printDebug)
    default void
    printError(com.sk89q.worldedit.util.formatting.text.Component component)
    Print a WorldEdit error.
    void
    Deprecated.
    Use component-based functions (printError)
    default void
    printInfo(com.sk89q.worldedit.util.formatting.text.Component component)
    Print a WorldEdit message.
    void
    Deprecated.
    Use component-based functions (print)
    default void
    Sends any relevant notices to the user when they first use WorldEdit in a session.

    Methods inherited from interface com.sk89q.worldedit.util.Identifiable

    getUniqueId

    Methods inherited from interface com.sk89q.worldedit.session.SessionOwner

    getSessionKey

    Methods inherited from interface com.sk89q.worldedit.util.auth.Subject

    checkPermission, getGroups, hasPermission
  • Method Details

    • getName

      String getName()
      Get the name of the actor.
      Returns:
      String
    • getDisplayName

      default String getDisplayName()
      Gets the display name of the actor. This can be a nickname, and is not guaranteed to be unique.
      Returns:
      The display name
    • printRaw

      @Deprecated void printRaw(String msg)
      Deprecated.
      Use component-based functions (print)
      Print a message.
      Parameters:
      msg - The message text
    • printDebug

      @Deprecated void printDebug(String msg)
      Deprecated.
      Use component-based functions (printDebug)
      Print a WorldEdit message.
      Parameters:
      msg - The message text
    • print

      @Deprecated void print(String msg)
      Deprecated.
      Use component-based functions (printInfo)
      Print a WorldEdit message.
      Parameters:
      msg - The message text
    • printError

      @Deprecated void printError(String msg)
      Deprecated.
      Use component-based functions (printError)
      Print a WorldEdit error.
      Parameters:
      msg - The error message text
    • printError

      default void printError(com.sk89q.worldedit.util.formatting.text.Component component)
      Print a WorldEdit error.
      Parameters:
      component - The component to print
    • printInfo

      default void printInfo(com.sk89q.worldedit.util.formatting.text.Component component)
      Print a WorldEdit message.
      Parameters:
      component - The component to print
    • printDebug

      default void printDebug(com.sk89q.worldedit.util.formatting.text.Component component)
      Print a WorldEdit message.
      Parameters:
      component - The component to print
    • print

      void print(com.sk89q.worldedit.util.formatting.text.Component component)
      Print a Component.
      Parameters:
      component - The component to print
    • canDestroyBedrock

      boolean canDestroyBedrock()
      Returns true if the actor can destroy bedrock.
      Returns:
      true if bedrock can be broken by the actor
    • isPlayer

      boolean isPlayer()
      Return whether this actor is a player.
      Returns:
      true if a player
    • openFileOpenDialog

      File openFileOpenDialog(String[] extensions)
      Open a file open dialog.
      Parameters:
      extensions - null to allow all
      Returns:
      the selected file or null if something went wrong
    • openFileSaveDialog

      File openFileSaveDialog(String[] extensions)
      Open a file save dialog.
      Parameters:
      extensions - null to allow all
      Returns:
      the selected file or null if something went wrong
    • dispatchCUIEvent

      void dispatchCUIEvent(CUIEvent event)
      Send a CUI event.
      Parameters:
      event - the event
    • getLocale

      Locale getLocale()
      Get the locale of this actor.
      Returns:
      The locale
    • sendAnnouncements

      default void sendAnnouncements()
      Sends any relevant notices to the user when they first use WorldEdit in a session.