Class CachedMask

All Implemented Interfaces:
ResettableMask, Resettable, Mask

public class CachedMask extends AbstractDelegateMask implements ResettableMask
  • Constructor Details

    • CachedMask

      public CachedMask(Mask mask)
  • Method Details

    • cache

      public static CachedMask cache(Mask mask)
    • reset

      public void reset()
      Specified by:
      reset in interface Resettable
      Specified by:
      reset in interface ResettableMask
    • test

      public boolean test(BlockVector3 vector)
      Description copied from interface: Mask
      Returns true if the criteria is met.
      Specified by:
      test in interface Mask
      Overrides:
      test in class AbstractDelegateMask
      Parameters:
      vector - the vector to test
      Returns:
      true if the criteria is met
    • test

      public boolean test(@Nullable Extent extent, BlockVector3 vector)
    • copy

      public Mask copy()
      Description copied from interface: Mask
      Returns a copy of the mask. Usually for multi-threaded operation
      Specified by:
      copy in interface Mask
      Overrides:
      copy in class AbstractDelegateMask
      Returns:
      a clone of the mask