Class EditSessionFactory

java.lang.Object
com.sk89q.worldedit.EditSessionFactory

@Deprecated public class EditSessionFactory extends Object
Deprecated.
Using the ever-extending factory methods is deprecated. Replace with EditSessionBuilder, which in most cases will be as simple as calling builder.world(world).build().
Creates new EditSessions. To get an instance of this factory, use WorldEdit.getEditSessionFactory().

It is no longer possible to replace the instance of this in WorldEdit with a custom one. Use EditSessionEvent to override the creation of EditSessions.

  • Constructor Details

    • EditSessionFactory

      public EditSessionFactory()
      Deprecated.
  • Method Details

    • getEditSession

      public EditSession getEditSession(World world, int maxBlocks)
      Deprecated.
      Construct an edit session with a maximum number of blocks.
      Parameters:
      world - the world
      maxBlocks - the maximum number of blocks that can be changed, or -1 to use no limit
      Returns:
      an instance
    • getEditSession

      public EditSession getEditSession(World world, int maxBlocks, Actor actor)
      Deprecated.
      Construct an edit session with a maximum number of blocks.
      Parameters:
      world - the world
      maxBlocks - the maximum number of blocks that can be changed, or -1 to use no limit
      actor - the actor that the EditSession is for
      Returns:
      an instance
    • getEditSession

      public EditSession getEditSession(World world, int maxBlocks, BlockBag blockBag)
      Deprecated.
      Construct an edit session with a maximum number of blocks and a block bag.
      Parameters:
      world - the world
      maxBlocks - the maximum number of blocks that can be changed, or -1 to use no limit
      blockBag - an optional BlockBag to use, otherwise null
      Returns:
      an instance
    • getEditSession

      public EditSession getEditSession(World world, int maxBlocks, BlockBag blockBag, Actor actor)
      Deprecated.
      Construct an edit session with a maximum number of blocks and a block bag.
      Parameters:
      world - the world
      maxBlocks - the maximum number of blocks that can be changed, or -1 to use no limit
      blockBag - an optional BlockBag to use, otherwise null
      actor - the actor that the EditSession is for
      Returns:
      an instance