Class AbstractFactoryWithPropertiesConfig<T extends AbstractFactoryWithPropertiesConfig<T>>

java.lang.Object
com.hazelcast.config.AbstractFactoryWithPropertiesConfig<T>
Type Parameters:
T - final child type
Direct Known Subclasses:
AuditlogConfig, SSLConfig

public abstract class AbstractFactoryWithPropertiesConfig<T extends AbstractFactoryWithPropertiesConfig<T>>
extends Object
Configuration base for config types with a factory class and its properties.
  • Field Details

    • enabled

      protected boolean enabled
    • factoryClassName

      protected String factoryClassName
    • properties

      protected Properties properties
  • Constructor Details

    • AbstractFactoryWithPropertiesConfig

      public AbstractFactoryWithPropertiesConfig()
  • Method Details

    • getFactoryClassName

      public String getFactoryClassName()
      Returns the factory class name.
    • setFactoryClassName

      public T setFactoryClassName​(@Nonnull String factoryClassName)
      Sets the factory class name.
    • isEnabled

      public boolean isEnabled()
      Returns if this configuration is enabled.
      Returns:
      true if enabled, false otherwise
    • setEnabled

      public T setEnabled​(boolean enabled)
      Enables and disables this configuration.
      Parameters:
      enabled - true to enable, false to disable
    • setProperty

      public T setProperty​(String name, String value)
      Sets a single property.
      Parameters:
      name - the name of the property to set
      value - the value of the property to set
      Returns:
      the updated config object (self)
      Throws:
      NullPointerException - if name or value is null
    • getProperty

      public String getProperty​(String name)
      Gets a property.
      Parameters:
      name - the name of the property to get
      Returns:
      the value of the property, null if not found
      Throws:
      NullPointerException - if name is null
    • getProperties

      public Properties getProperties()
      Gets all properties.
      Returns:
      the properties
    • setProperties

      public T setProperties​(@Nonnull Properties properties)
      Sets the properties.
      Parameters:
      properties - the properties to set
      Returns:
      the updated config object (self)
      Throws:
      IllegalArgumentException - if properties is null
    • toString

      public String toString()
      Overrides:
      toString in class Object
    • equals

      public boolean equals​(Object o)
      Overrides:
      equals in class Object
    • hashCode

      public int hashCode()
      Overrides:
      hashCode in class Object
    • self

      protected abstract T self()