Class TokenisedSubjectUtil


  • public class TokenisedSubjectUtil
    extends java.lang.Object
    Util to retrieve values from a given subject defined by the namespace and tokens that the namespace.
    • Method Summary

      All Methods Static Methods Concrete Methods 
      Modifier and Type Method Description
      static java.lang.String getUsername​(java.lang.String subject, java.lang.String... nameSpaces)
      Retrieve username from subject based on nameSpace location.
      static java.lang.String getVariable​(java.lang.String subject, java.lang.String variableToken, java.lang.String... nameSpaces)
      Retrieve value from subject for the token defined in namespaces given.
      static boolean isValid​(java.lang.String subject, java.lang.String tokenisedNamespace, java.lang.String... variableTokens)  
      • Methods inherited from class java.lang.Object

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

      • TokenisedSubjectUtil

        public TokenisedSubjectUtil()
    • Method Detail

      • isValid

        public static boolean isValid​(java.lang.String subject,
                                      java.lang.String tokenisedNamespace,
                                      java.lang.String... variableTokens)
      • getUsername

        public static java.lang.String getUsername​(java.lang.String subject,
                                                   java.lang.String... nameSpaces)
        Retrieve username from subject based on nameSpace location.
        Parameters:
        subject - contains subject to obtain username
        nameSpaces - contains String for nameSpace location
        Returns:
        username or null.
      • getVariable

        public static java.lang.String getVariable​(java.lang.String subject,
                                                   java.lang.String variableToken,
                                                   java.lang.String... nameSpaces)
        Retrieve value from subject for the token defined in namespaces given.
        Parameters:
        subject - String for subject to return
        variableToken - contains value for defined token
        nameSpaces - contains the String for nameSpaces
        Returns:
        value defined by token or null.clear