Class SubjectMapping
- java.lang.Object
-
- com.caplin.keymaster.permissioning.SubjectMapping
-
- All Implemented Interfaces:
ISubjectMapping
public class SubjectMapping extends java.lang.Object implements ISubjectMapping
An implementation of theISubjectMapping
interface. You must create instances of this class if you want to use tiering or subject mapping.
-
-
Constructor Summary
Constructors Constructor Description SubjectMapping(java.lang.String mapFromPattern, java.lang.String mapToPattern)
Initializes a new instance of theSubjectMapping
class.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.String
getMapFromPattern()
Gets the pattern that will match a request for a subject.java.lang.String
getMapToPattern()
Gets the pattern that client requests matchingISubjectMapping.getMapFromPattern()
will be mapped to.void
setMapFromPattern(java.lang.String value)
Sets the pattern that will match a request for a subject.void
setMapToPattern(java.lang.String value)
Sets the pattern that client requests matchingISubjectMapping.getMapFromPattern()
will be mapped to.java.lang.String
toString()
Returns a String that represents this instance.
-
-
-
Constructor Detail
-
SubjectMapping
public SubjectMapping(java.lang.String mapFromPattern, java.lang.String mapToPattern)
Initializes a new instance of theSubjectMapping
class.- Parameters:
mapFromPattern
- The pattern that will match a request for a subject. See thegetMapFromPattern()
method.mapToPattern
- The pattern that client requests matchingmapFromPattern
will be mapped to. See thegetMapToPattern()
method.
-
-
Method Detail
-
getMapFromPattern
public java.lang.String getMapFromPattern()
Description copied from interface:ISubjectMapping
Gets the pattern that will match a request for a subject.The pattern is an Extended regular expression and can contain captures.
- Specified by:
getMapFromPattern
in interfaceISubjectMapping
- Returns:
- The pattern.
-
setMapFromPattern
public void setMapFromPattern(java.lang.String value)
Description copied from interface:ISubjectMapping
Sets the pattern that will match a request for a subject.The pattern is an Extended regular expression and can contain captures.
- Specified by:
setMapFromPattern
in interfaceISubjectMapping
- Parameters:
value
- The pattern.
-
getMapToPattern
public java.lang.String getMapToPattern()
Description copied from interface:ISubjectMapping
Gets the pattern that client requests matchingISubjectMapping.getMapFromPattern()
will be mapped to.The pattern should contain references to capture registers.
- Specified by:
getMapToPattern
in interfaceISubjectMapping
- Returns:
- The pattern.
-
setMapToPattern
public void setMapToPattern(java.lang.String value)
Description copied from interface:ISubjectMapping
Sets the pattern that client requests matchingISubjectMapping.getMapFromPattern()
will be mapped to.The pattern should contain references to capture registers.
- Specified by:
setMapToPattern
in interfaceISubjectMapping
- Parameters:
value
- The Pattern.
-
toString
public java.lang.String toString()
Returns a String that represents this instance.- Overrides:
toString
in classjava.lang.Object
-
-