Class SystemPropertyInitializer

java.lang.Object
org.springframework.batch.support.SystemPropertyInitializer
All Implemented Interfaces:
org.springframework.beans.factory.InitializingBean

@Deprecated(since="5.2.0", forRemoval=true) public class SystemPropertyInitializer extends Object implements org.springframework.beans.factory.InitializingBean
Deprecated, for removal: This API element is subject to removal in a future version.
since 5.2 with no replacement.
Helper class that sets up a System property with a default value. A System property is created with the specified key name, and default value (i.e. if the property already exists it is not changed).
Author:
Dave Syer
  • Field Summary

    Fields
    Modifier and Type
    Field
    Description
    static final String
    Deprecated, for removal: This API element is subject to removal in a future version.
    Name of system property used by default.
  • Constructor Summary

    Constructors
    Constructor
    Description
    Deprecated, for removal: This API element is subject to removal in a future version.
     
  • Method Summary

    Modifier and Type
    Method
    Description
    void
    Deprecated, for removal: This API element is subject to removal in a future version.
    Sets the System property with the provided name and default value.
    void
    setDefaultValue(String defaultValue)
    Deprecated, for removal: This API element is subject to removal in a future version.
    Mandatory property specifying the default value of the System property.
    void
    setKeyName(String keyName)
    Deprecated, for removal: This API element is subject to removal in a future version.
    Set the key name for the System property that is created.

    Methods inherited from class java.lang.Object

    clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • Field Details

    • ENVIRONMENT

      public static final String ENVIRONMENT
      Deprecated, for removal: This API element is subject to removal in a future version.
      Name of system property used by default.
      See Also:
  • Constructor Details

    • SystemPropertyInitializer

      public SystemPropertyInitializer()
      Deprecated, for removal: This API element is subject to removal in a future version.
  • Method Details

    • setKeyName

      public void setKeyName(String keyName)
      Deprecated, for removal: This API element is subject to removal in a future version.
      Set the key name for the System property that is created. Defaults to ENVIRONMENT.
      Parameters:
      keyName - the key name to set
    • setDefaultValue

      public void setDefaultValue(String defaultValue)
      Deprecated, for removal: This API element is subject to removal in a future version.
      Mandatory property specifying the default value of the System property.
      Parameters:
      defaultValue - the default value to set
    • afterPropertiesSet

      public void afterPropertiesSet() throws Exception
      Deprecated, for removal: This API element is subject to removal in a future version.
      Sets the System property with the provided name and default value.
      Specified by:
      afterPropertiesSet in interface org.springframework.beans.factory.InitializingBean
      Throws:
      Exception
      See Also:
      • InitializingBean.afterPropertiesSet()