Class CredentialConfigParser


  • public class CredentialConfigParser
    extends java.lang.Object
    Parses the configuration data associated with credential configs and ssl socket factories. The format of the property string should be like:
       MySSLSocketFactory
         {KeyStoreCredentialConfig
           {{trustStore=/tmp/my.truststore}{trustStoreType=JKS}}}
     

    or

       {KeyStoreCredentialConfig
         {{trustStore=/tmp/my.truststore}{trustStoreType=JKS}}}
     

    or

       {{trustCertificates=/tmp/my.crt}}
     
    Version:
    $Revision: 930 $ $Date: 2009-10-26 16:44:26 -0400 (Mon, 26 Oct 2009) $
    Author:
    Middleware Services
    • Constructor Summary

      Constructors 
      Constructor Description
      CredentialConfigParser​(java.lang.String config)
      Creates a new CredentialConfigParser with the supplied configuration string.
    • Method Summary

      All Methods Static Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      java.lang.String getCredentialConfigClassName()
      Returns the credential config class name from the configuration.
      java.util.Map<java.lang.String,​java.lang.String> getProperties()
      Returns the properties from the configuration.
      java.lang.String getSslSocketFactoryClassName()
      Returns the SSL socket factory class name from the configuration.
      java.lang.Object initializeType()
      Initialize an instance of credential config with the properties contained in this config.
      static boolean isCredentialConfig​(java.lang.String config)
      Returns whether the supplied configuration data contains a credential config.
      protected void setProperties​(java.lang.Class<?> c, java.lang.Object o)
      Sets the properties on the supplied object.
      • Methods inherited from class java.lang.Object

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

      • CredentialConfigParser

        public CredentialConfigParser​(java.lang.String config)
        Creates a new CredentialConfigParser with the supplied configuration string.
        Parameters:
        config - String
    • Method Detail

      • getSslSocketFactoryClassName

        public java.lang.String getSslSocketFactoryClassName()
        Returns the SSL socket factory class name from the configuration.
        Returns:
        String class name
      • getCredentialConfigClassName

        public java.lang.String getCredentialConfigClassName()
        Returns the credential config class name from the configuration.
        Returns:
        String class name
      • getProperties

        public java.util.Map<java.lang.String,​java.lang.String> getProperties()
        Returns the properties from the configuration.
        Returns:
        Map of property name to value
      • isCredentialConfig

        public static boolean isCredentialConfig​(java.lang.String config)
        Returns whether the supplied configuration data contains a credential config.
        Parameters:
        config - String
        Returns:
        boolean
      • initializeType

        public java.lang.Object initializeType()
        Initialize an instance of credential config with the properties contained in this config.
        Returns:
        Object of the type CredentialConfig
      • setProperties

        protected void setProperties​(java.lang.Class<?> c,
                                     java.lang.Object o)
        Sets the properties on the supplied object.
        Parameters:
        c - Class type of the supplied object
        o - Object to invoke properties on