public abstract class OrgReferral extends Object implements Referral
Modifier and Type | Field and Description |
---|---|
protected Map |
_configurationMap |
protected String |
_orgName |
protected Cache |
cachedPolicyEvaluators |
protected static String |
CAN_NOT_GET_VALUES_FOR_REFERRAL |
protected static Debug |
DEBUG |
Constructor and Description |
---|
OrgReferral()
No argument constructor
|
Modifier and Type | Method and Description |
---|---|
String |
getDisplayNameForValue(String value,
Locale locale)
Returns the display name for the value for the given locale.
|
PolicyDecision |
getPolicyDecision(SSOToken token,
String resourceType,
String resourceName,
Set actionNames,
Map envParameters)
Gets policy evaluation results
|
abstract String |
getReferralTypeName()
Gets the name of the ReferralType
|
Set |
getResourceNames(SSOToken token,
String serviceTypeName,
String resourceName)
Gets resource names that are exact matches, sub resources or
wild card matches of argument resource name.
|
abstract ValidValues |
getValidValues(SSOToken token)
Gets the valid values for this referral
|
abstract ValidValues |
getValidValues(SSOToken token,
String pattern)
Gets the valid values for this referral matching a pattern
|
Set |
getValues()
Gets the values of this referral
|
Syntax |
getValueSyntax(SSOToken token)
Returns the syntax of the values the
OrgReferral |
void |
initialize(Map configurationMap)
Initializes the referral with a map of Configuration parameters
|
void |
setValues(Set values)
Sets the values of this referral.
|
protected static final Debug DEBUG
protected static final String CAN_NOT_GET_VALUES_FOR_REFERRAL
protected Map _configurationMap
protected String _orgName
protected Cache cachedPolicyEvaluators
public void initialize(Map configurationMap)
initialize
in interface Referral
configurationMap
- a map containing configuration
information. Each key of the map is a configuration
parameter. Each value of the key would be a set of values
for the parameter. The map is cloned and a reference to the
clone is stored in the referralpublic void setValues(Set values) throws InvalidNameException
setValues
in interface Referral
values
- a set of values for this referral
Each element of the set has to be a StringInvalidNameException
- if any value passed in the
values is invalidpublic Set getValues()
public String getDisplayNameForValue(String value, Locale locale) throws NameNotFoundException
getValidValues
this method must be called
by GUI and CLI to get the corresponding display name.
The locale
variable could be used by the
plugin to customize
the display name for the given locale.
The locale
variable
could be null
, in which case the plugin must
use the default locale (most probabily en_US).
This method returns only the display name and should not
be used for the method setValues
.
Alternatively, if the plugin does not have to localize
the value, it can just return the value
as is.getDisplayNameForValue
in interface Referral
value
- one of the valid value for the pluginlocale
- locale for which the display name must be customizedNameNotFoundException
- if the given value
is not one of the valid values for the pluginpublic abstract ValidValues getValidValues(SSOToken token) throws SSOException, PolicyException
getValidValues
in interface Referral
token
- SSOTokenValidValues
objectSSOException
- if SSOToken>
is not validPolicyException
- if unable to get the list of valid
names.public abstract ValidValues getValidValues(SSOToken token, String pattern) throws SSOException, PolicyException
getValidValues
in interface Referral
token
- SSOTokenpattern
- a pattern to match against the valueSSOException
- if SSOToken>
is not validPolicyException
- if unable to get the list of valid
names.public Syntax getValueSyntax(SSOToken token) throws SSOException, PolicyException
OrgReferral
getValueSyntax
in interface Referral
token
- the SSOToken
that will be used
to determine the syntaxSSOException
- if SSOToken>
is not validPolicyException
Syntax
public abstract String getReferralTypeName()
getReferralTypeName
in interface Referral
public PolicyDecision getPolicyDecision(SSOToken token, String resourceType, String resourceName, Set actionNames, Map envParameters) throws SSOException, PolicyException
getPolicyDecision
in interface Referral
token
- SSOTokenresourceType
- resource typeresourceName
- name of the resourceactionNames
- a set of action namesenvParameters
- a map of enivronment parameters.
Each key is an environment parameter name.
Each value is a set of values for the parameter.SSOException
PolicyException
public Set getResourceNames(SSOToken token, String serviceTypeName, String resourceName) throws PolicyException, SSOException
getResourceNames
in interface Referral
token
- sso tokenserviceTypeName
- service type nameresourceName
- resource namePolicyException
- if unable to get the Set of
resource names.SSOException
- is the token is invalid.ResourceMatch.EXACT_MATCH
,
ResourceMatch.SUB_RESOURCE_MATCH
,
ResourceMatch.WILDCARD_MATCH
Copyright © 2010–2025 Open Identity Platform Community. All rights reserved.