Class SemaphoreConfig

java.lang.Object
com.hazelcast.config.cp.SemaphoreConfig

public class SemaphoreConfig extends Object
Contains configuration options for CP ISemaphore
  • Field Details

    • DEFAULT_SEMAPHORE_JDK_COMPATIBILITY

      public static final boolean DEFAULT_SEMAPHORE_JDK_COMPATIBILITY
      The default value for the JDK compatibility mode of CP ISemaphore
      See Also:
    • DEFAULT_INITIAL_PERMITS

      public static final int DEFAULT_INITIAL_PERMITS
      Default value for the initial permit count of Semaphores.
      See Also:
  • Constructor Details

    • SemaphoreConfig

      public SemaphoreConfig()
    • SemaphoreConfig

      public SemaphoreConfig(String name)
    • SemaphoreConfig

      public SemaphoreConfig(String name, boolean jdkCompatible, int initialPermits)
  • Method Details

    • getName

      public String getName()
      Returns the name of CP ISemaphore
    • setName

      public SemaphoreConfig setName(String name)
      Sets the name of CP ISemaphore
    • isJDKCompatible

      public boolean isJDKCompatible()
      Returns true if CP ISemaphore is compatible with its JDK counterpart
    • setJDKCompatible

      public SemaphoreConfig setJDKCompatible(boolean jdkCompatible)
      Sets JDK compatibility mode of CP ISemaphore
    • getInitialPermits

      public int getInitialPermits()
      Returns initial permit count of the Semaphore
    • setInitialPermits

      public SemaphoreConfig setInitialPermits(int initialPermits)
      Sets initial permit count of the Semaphore
    • toString

      public String toString()
      Overrides:
      toString in class Object