Class EditSessionBuilder

java.lang.Object
com.sk89q.worldedit.EditSessionBuilder

public final class EditSessionBuilder extends Object
A builder-style factory for EditSessions.
  • Method Details

    • getWorld

      @Nullable public World getWorld()
    • world

      public EditSessionBuilder world(@Nullable World world)
      Set the world for the EditSession.
      Parameters:
      world - the world
      Returns:
      this builder
    • getMaxBlocks

      public int getMaxBlocks()
    • maxBlocks

      public EditSessionBuilder maxBlocks(int maxBlocks)
      Set the maximum blocks to change for the EditSession.
      Parameters:
      maxBlocks - the maximum blocks to change
      Returns:
      this builder
    • getActor

      @Nullable public Actor getActor()
    • actor

      public EditSessionBuilder actor(@Nullable Actor actor)
      Set the actor who owns the EditSession.
      Parameters:
      actor - the actor
      Returns:
      this builder
    • getBlockBag

      @Nullable public BlockBag getBlockBag()
    • blockBag

      public EditSessionBuilder blockBag(@Nullable BlockBag blockBag)
      Set the block bag for the EditSession.
      Parameters:
      blockBag - the block bag
      Returns:
      this builder
    • isTracing

      public boolean isTracing()
      Check if tracing is enabled. Internal use only.
    • tracing

      public EditSessionBuilder tracing(boolean tracing)
      Set tracing enabled/disabled. Internal use only.
    • locatableActor

      public <A extends Actor & Locatable> EditSessionBuilder locatableActor(A locatable)
    • build

      public EditSession build()
      Build the EditSession using properties described in this builder.
      Returns:
      the new EditSession