Class Properties

  • All Implemented Interfaces:

    
    public class Properties
    
                        

    Utility method for accessing system properties.

    • Nested Class Summary

      Nested Classes 
      Modifier and Type Class Description
    • Field Summary

      Fields 
      Modifier and Type Field Description
    • Constructor Summary

      Constructors 
      Constructor Description
    • Enum Constant Summary

      Enum Constants 
      Enum Constant Description
    • Method Summary

      Modifier and Type Method Description
      static boolean isOverrideSet(String propertyName) Return whether a particular override has been set to true.
      static boolean isOverrideSetTo(String propertyName, boolean isTrue) Return whether a particular override has been set to false.
      static boolean setThreadOverride(String propertyName, boolean enable) Enable the specified override property for the current thread only.
      static boolean removeThreadOverride(String propertyName) Remove any value for the specified override property for the current thread only.
      static BigInteger asBigInteger(String propertyName)
      static Set<String> asKeySet(String propertyName)
      static String getPropertyValue(String propertyName)
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

    • Method Detail

      • isOverrideSet

         static boolean isOverrideSet(String propertyName)

        Return whether a particular override has been set to true.

        Parameters:
        propertyName - the property name for the override.
        Returns:

        true if the property is set to "true", false otherwise.

      • isOverrideSetTo

         static boolean isOverrideSetTo(String propertyName, boolean isTrue)

        Return whether a particular override has been set to false.

        Parameters:
        propertyName - the property name for the override.
        isTrue - true if the override should be true, false otherwise.
        Returns:

        true if the property is set to the value of isTrue, false otherwise.

      • setThreadOverride

         static boolean setThreadOverride(String propertyName, boolean enable)

        Enable the specified override property for the current thread only.

        Parameters:
        propertyName - the property name for the override.
        enable - true if the override should be enabled, false if it should be disabled.
        Returns:

        true if the override was already set true, false otherwise.

      • removeThreadOverride

         static boolean removeThreadOverride(String propertyName)

        Remove any value for the specified override property for the current thread only.

        Parameters:
        propertyName - the property name for the override.
        Returns:

        true if the override was already set true in thread local, false otherwise.