public interface IPolicyDefault extends IConfigTemplate
During request submission process, a default policy is invoked to populate the default values in the request. The default values will later on be used for execution. The default values are like the parameters for the request.
This policy is called in 2 places. For automated enrollment request, this policy is invoked to populate the HTTP parameters into the request. For request that cannot be executed immediately, this policy will be invoked again right after the agent's approval.
Each default policy may contain zero or more properties that describe the default value. For example, a X509 Key can be described by its key type, key length, and key data. The properties help to describe the default value into human readable values.
Modifier and Type | Method and Description |
---|---|
IConfigStore |
getConfigStore()
Retrieves the configuration store of this default.
|
java.lang.String |
getName(java.util.Locale locale)
Retrieves the localizable name of this policy.
|
java.lang.String |
getText(java.util.Locale locale)
Retrieves the localizable description of this policy.
|
java.lang.String |
getValue(java.lang.String name,
java.util.Locale locale,
IRequest request)
Retrieves the value of the given value
property by name.
|
IDescriptor |
getValueDescriptor(java.util.Locale locale,
java.lang.String name)
Retrieves the descriptor of the given property
by name.
|
java.util.Enumeration |
getValueNames()
Retrieves a list of names of the property.
|
void |
init(IProfile profile,
IConfigStore config)
Initializes this default policy.
|
void |
populate(IRequest request)
Populates the request with this policy default.
|
void |
setValue(java.lang.String name,
java.util.Locale locale,
IRequest request,
java.lang.String value)
Sets the value of the given value property by name.
|
getConfig, getConfigDescriptor, getConfigNames, setConfig
void init(IProfile profile, IConfigStore config) throws EProfileException
profile
- owner of this default policyconfig
- configuration store for this defaultEProfileException
- failed to initializeIConfigStore getConfigStore()
void populate(IRequest request) throws EProfileException
request
- request to be populatedEProfileException
- failed to populatejava.lang.String getName(java.util.Locale locale)
locale
- locale of the end userjava.lang.String getText(java.util.Locale locale)
locale
- locale of the end userjava.util.Enumeration getValueNames()
IDescriptor getValueDescriptor(java.util.Locale locale, java.lang.String name)
locale
- locale of the end username
- name of propertyvoid setValue(java.lang.String name, java.util.Locale locale, IRequest request, java.lang.String value) throws EPropertyException
name
- name of propertylocale
- locale of the end userrequest
- requestvalue
- value to be set in the given requestEPropertyException
- failed to set propertyjava.lang.String getValue(java.lang.String name, java.util.Locale locale, IRequest request) throws EPropertyException
name
- name of propertylocale
- locale of the end userrequest
- requestEPropertyException
- failed to get property