java.lang.Object
io.github.rysefoxx.inventory.plugin.pagination.SlotIterator

public class SlotIterator extends Object
  • Constructor Details

    • SlotIterator

      public SlotIterator()
  • Method Details

    • builder

      @Contract(" -> new") @NotNull public static @NotNull SlotIterator.Builder builder()
    • getPatternBuilder

      @Nullable public @Nullable SlotIteratorPattern getPatternBuilder()
      Returns:
      the pattern builder.
    • getSlot

      @Nonnegative public int getSlot()
      Returns:
      the start slot
    • getColumn

      @Nonnegative public int getColumn()
      Returns:
      the start column
    • getRow

      @Nonnegative public int getRow()
      Returns:
      the start row
    • getType

      @NotNull public @NotNull SlotIterator.SlotIteratorType getType()
      Returns:
      the SlotIteratorType
    • isOverride

      public boolean isOverride()
      Returns:
      true if items can be overwritten.
    • getEndPosition

      public int getEndPosition()
      Returns:
      where the last item should be placed.

      If the endPosition was set, the Pagination.setItemsPerPage(int) specification is ignored.

    • getBlackList

      @NotNull public @Unmodifiable @NotNull List<Integer> getBlackList() throws UnsupportedOperationException
      Returns:
      all slots where no items should be placed.
      Throws:
      UnsupportedOperationException - When modifying the returned list.
    • getBlackListInternal

      @NotNull protected @NotNull List<Integer> getBlackListInternal()