com.ibm.mfp.server.security.external.checks.impl

Class SecurityCheckConfigurationBase

  • java.lang.Object
    • com.ibm.mfp.server.security.external.checks.impl.SecurityCheckConfigurationBase
    • Field Summary

      Fields 
      Modifier and Type Field and Description
      protected java.util.Map errors 
      protected java.util.Map info 
      protected java.util.Map warnings 
    • Method Summary

      Methods 
      Modifier and Type Method and Description
      protected void addMessage(java.util.Map map, java.lang.String property, java.lang.String msg) 
      java.util.Map getErrors()
      Get validation errors as a map with property name as key and error message as value
      java.util.Map getInfo()
      Get validation warnings as a map with property name as key and warning message as value
      protected int getIntProperty(java.lang.String name, java.util.Properties properties, java.lang.Integer defaultValue)
      Find property with the given name in Properties and convert it to int.
      protected java.lang.String getStringProperty(java.lang.String name, java.util.Properties properties, java.lang.String defaultValue)
      Find property with the given name in Properties.
      java.util.Map getWarnings()
      Get validation warnings as a map with property name as key and warning message as value
      • Methods inherited from class java.lang.Object

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

      • errors

        protected java.util.Map errors
      • warnings

        protected java.util.Map warnings
      • info

        protected java.util.Map info
    • Constructor Detail

      • SecurityCheckConfigurationBase

        public SecurityCheckConfigurationBase()
    • Method Detail

      • getInfo

        public java.util.Map getInfo()
        Description copied from interface: SecurityCheckConfiguration
        Get validation warnings as a map with property name as key and warning message as value
        Specified by:
        getInfo in interface SecurityCheckConfiguration
        Returns:
        validation warnings, may be null
      • getStringProperty

        protected java.lang.String getStringProperty(java.lang.String name,
                                         java.util.Properties properties,
                                         java.lang.String defaultValue)
        Find property with the given name in Properties. If the property exists, it is removed from input Properties to allow tracking unused properties. If the property does not exist and the default value is not null, a "missing property" warning is reported, and the default is returned as a result If the property does not exist and the default value is null, a "missing property" error is reported.
        Parameters:
        name - the property name
        properties - the properties to get from, modified by the method
        defaultValue - the value to return if the property does not exist, null means the property is mandatory
        Returns:
        property value if the property exists. If the property does not exist - default value if provided, null otherwise
      • getIntProperty

        protected int getIntProperty(java.lang.String name,
                         java.util.Properties properties,
                         java.lang.Integer defaultValue)
        Find property with the given name in Properties and convert it to int. If the property exists, it is removed from input Properties to allow tracking unused properties. If the value cannot be converted to int, an "invalid value" error is reported If the property does not exist and the default value is not null, a "missing property" warning is reported, and the default is returned as a result If the property does not exist and the default value is null, a "missing property" error is reported.
        Parameters:
        name - the property name
        properties - the properties to get from, modified by the method
        defaultValue - the value to return if the property does not exist, null means the property is mandatory
        Returns:
        property value if the property exists. If the property does not exist - default value if provided, -1 otherwise
      • addMessage

        protected void addMessage(java.util.Map map,
                      java.lang.String property,
                      java.lang.String msg)


© Copyright IBM Corp. 2006, 2015. All Rights Reserved.