Class ListeningWhitelist.Builder

java.lang.Object
com.comphenix.protocol.events.ListeningWhitelist.Builder
Enclosing class:
ListeningWhitelist

public static class ListeningWhitelist.Builder extends Object
Represents a builder of whitelists.
  • Method Details

    • priority

      public ListeningWhitelist.Builder priority(ListenerPriority priority)
      Set the priority to use when constructing new whitelists.
      Parameters:
      priority - - the priority.
      Returns:
      This builder, for chaining.
    • monitor

      public ListeningWhitelist.Builder monitor()
      Set the priority of the whitelist to monitor.
      Returns:
      This builder, for chaining.
    • normal

      public ListeningWhitelist.Builder normal()
      Set the priority of the whitelist to normal.
      Returns:
      This builder, for chaining.
    • lowest

      public ListeningWhitelist.Builder lowest()
      Set the priority of the whitelist to lowest.
      Returns:
      This builder, for chaining.
    • low

      Set the priority of the whitelist to low.
      Returns:
      This builder, for chaining.
    • highest

      public ListeningWhitelist.Builder highest()
      Set the priority of the whitelist to highest.
      Returns:
      This builder, for chaining.
    • high

      Set the priority of the whitelist to high.
      Returns:
      This builder, for chaining.
    • types

      public ListeningWhitelist.Builder types(PacketType... types)
      Set the whitelist of packet types to copy when constructing new whitelists.
      Parameters:
      types - - the whitelist of packets.
      Returns:
      This builder, for chaining.
    • types

      Set the whitelist of packet types to copy when constructing new whitelists.
      Parameters:
      types - - the whitelist of packets.
      Returns:
      This builder, for chaining.
    • gamePhase

      @Deprecated public ListeningWhitelist.Builder gamePhase(GamePhase gamePhase)
      Deprecated.
      Set the gamephase to use when constructing new whitelists.
      Parameters:
      gamePhase - - the gamephase.
      Returns:
      This builder, for chaining.
    • gamePhaseBoth

      @Deprecated public ListeningWhitelist.Builder gamePhaseBoth()
      Deprecated.
      Set the gamephase to GamePhase.BOTH.
      Returns:
      This builder, for chaining.
    • options

      public ListeningWhitelist.Builder options(Set<ListenerOptions> options)
      Set the options to copy when constructing new whitelists.
      Parameters:
      options - - the options.
      Returns:
      This builder, for chaining.
    • options

      Set the options to copy when constructing new whitelists.
      Parameters:
      options - - the options.
      Returns:
      This builder, for chaining.
    • options

      public ListeningWhitelist.Builder options(ListenerOptions[] serverOptions)
      Set the options to copy when constructing new whitelists.
      Parameters:
      serverOptions - - the options array.
      Returns:
      This builder, for chaining.
    • mergeOptions

      public ListeningWhitelist.Builder mergeOptions(ListenerOptions... serverOptions)
      Options to merge into the current set of options.
      Parameters:
      serverOptions - - the options array.
      Returns:
      This builder, for chaining.
    • mergeOptions

      public ListeningWhitelist.Builder mergeOptions(Collection<ListenerOptions> serverOptions)
      Options to merge into the current set of options.
      Parameters:
      serverOptions - - the options array.
      Returns:
      This builder, for chaining.
    • build

      public ListeningWhitelist build()
      Construct a new whitelist from the values in this builder.
      Returns:
      The new whitelist.