Class HazelcastProperty


  • public final class HazelcastProperty
    extends java.lang.Object
    Interface for Hazelcast Member and Client properties.
    • Constructor Detail

      • HazelcastProperty

        public HazelcastProperty​(java.lang.String name)
      • HazelcastProperty

        public HazelcastProperty​(java.lang.String name,
                                 java.util.function.Function<HazelcastProperties,​?> function)
      • HazelcastProperty

        public HazelcastProperty​(java.lang.String name,
                                 java.lang.Enum<?> defaultEnum)
      • HazelcastProperty

        public HazelcastProperty​(java.lang.String name,
                                 boolean defaultValue)
      • HazelcastProperty

        public HazelcastProperty​(java.lang.String name,
                                 java.lang.Integer defaultValue)
      • HazelcastProperty

        public HazelcastProperty​(java.lang.String name,
                                 java.lang.Long defaultValue)
      • HazelcastProperty

        public HazelcastProperty​(java.lang.String name,
                                 java.lang.Double defaultValue)
      • HazelcastProperty

        public HazelcastProperty​(java.lang.String name,
                                 java.lang.Float defaultValue)
      • HazelcastProperty

        public HazelcastProperty​(java.lang.String name,
                                 java.lang.Byte defaultValue)
      • HazelcastProperty

        public HazelcastProperty​(java.lang.String name,
                                 java.lang.Integer defaultValue,
                                 java.util.concurrent.TimeUnit timeUnit)
      • HazelcastProperty

        public HazelcastProperty​(java.lang.String name,
                                 java.lang.Long defaultValue,
                                 java.util.concurrent.TimeUnit timeUnit)
      • HazelcastProperty

        public HazelcastProperty​(java.lang.String name,
                                 HazelcastProperty property)
      • HazelcastProperty

        public HazelcastProperty​(java.lang.String name,
                                 java.lang.String defaultValue)
      • HazelcastProperty

        protected HazelcastProperty​(java.lang.String name,
                                    java.lang.String defaultValue,
                                    java.util.concurrent.TimeUnit timeUnit)
      • HazelcastProperty

        public HazelcastProperty​(java.lang.String name,
                                 java.lang.String defaultValue,
                                 java.util.concurrent.TimeUnit timeUnit,
                                 HazelcastProperty parent)
    • Method Detail

      • setDeprecatedName

        public HazelcastProperty setDeprecatedName​(java.lang.String deprecatedName)
        Sets the deprecated name of this property. Useful if compatibility needs to be provided on property names. This method is thread-safe, but is expected to be called immediately after the HazelcastProperty is constructed. HazelcastProperty property = new HazelcastProperty("newname").setDeprecatedName("oldname");
        Parameters:
        deprecatedName - the deprecated name of the property
        Returns:
        the updated HazelcastProperty
        Throws:
        java.lang.IllegalArgumentException - if the deprecatedName is null or an empty string.
      • getDeprecatedName

        public java.lang.String getDeprecatedName()
      • getName

        public java.lang.String getName()
        Returns the property name.
        Returns:
        the property name
      • getDefaultValue

        public java.lang.String getDefaultValue()
        Returns the default value of the property.
        Returns:
        the default value or null if none is defined
      • getTimeUnit

        public java.util.concurrent.TimeUnit getTimeUnit()
        Returns the TimeUnit of the property.
        Returns:
        the TimeUnit
        Throws:
        java.lang.IllegalArgumentException - if no TimeUnit is defined
      • setSystemProperty

        public void setSystemProperty​(java.lang.String value)
        Sets the system property value of the property.
        Parameters:
        value - the value to set
      • getSystemProperty

        public java.lang.String getSystemProperty()
        Gets the system property value of the property.
        Returns:
        the value of the property
      • toString

        public java.lang.String toString()
        Overrides:
        toString in class java.lang.Object