Package com.netscape.cmscore.ldap
Class LdapRule
- java.lang.Object
-
- com.netscape.cmscore.ldap.LdapRule
-
- All Implemented Interfaces:
IExtendedPluginInfo
,ILdapPlugin
,ILdapRule
public class LdapRule extends java.lang.Object implements ILdapRule, IExtendedPluginInfo
The publishing rule that links mapper and publisher together.
-
-
Field Summary
Fields Modifier and Type Field Description static org.slf4j.Logger
logger
protected ILdapExpression
mFilterExp
static java.lang.String
NOMAPPER
-
Fields inherited from interface com.netscape.certsrv.base.IExtendedPluginInfo
HELP_TEXT, HELP_TOKEN
-
Fields inherited from interface com.netscape.certsrv.publish.ILdapRule
PROP_ENABLE, PROP_IMPLNAME, PROP_PREDICATE
-
-
Constructor Summary
Constructors Constructor Description LdapRule()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description boolean
enabled()
Returns true if the rule is enabled, false if it's disabled.IConfigStore
getConfigStore()
Return config store.java.util.Vector<java.lang.String>
getDefaultParams()
Returns the initial default parameters.java.lang.String
getDescription()
Returns the description of the ldap publisher.java.lang.String[]
getExtendedPluginInfo(java.util.Locale locale)
This method returns an array of strings.java.lang.String
getImplName()
Returns the implementation name.java.lang.String
getInstanceName()
Returns the instance namejava.util.Vector<java.lang.String>
getInstanceParams()
Returns the current instance parameters.java.lang.String
getMapper()
ILdapExpression
getPredicate()
Returns the predicate expression for the rule.java.lang.String
getPublisher()
java.lang.String
getType()
void
init(IConfigStore config)
The init method in ILdapPlugin It can not set set mapper,publisher choice for console dynamicly Should not use this method to init.void
init(PublisherProcessor processor, IConfigStore config)
Initialize the plugin.void
setInstanceName(java.lang.String insName)
Set the instance namevoid
setPredicate(ILdapExpression exp)
Sets a predicate expression for rule matching.
-
-
-
Field Detail
-
logger
public static org.slf4j.Logger logger
-
NOMAPPER
public static final java.lang.String NOMAPPER
- See Also:
- Constant Field Values
-
mFilterExp
protected ILdapExpression mFilterExp
-
-
Method Detail
-
getConfigStore
public IConfigStore getConfigStore()
Description copied from interface:ILdapPlugin
Return config store.- Specified by:
getConfigStore
in interfaceILdapPlugin
-
getExtendedPluginInfo
public java.lang.String[] getExtendedPluginInfo(java.util.Locale locale)
Description copied from interface:IExtendedPluginInfo
This method returns an array of strings. Each element of the array represents a configurable parameter, or some other meta-info (such as help-token) there is an entry indexed on that parameter name; [,required]; ;... Where: type_info is either 'string', 'number', 'boolean', 'password' or 'choice(ch1,ch2,ch3,...)' If the marker 'required' is included after the type_info, the parameter will has some visually distinctive marking in the UI. 'description' is a short sentence describing the parameter 'choice' is rendered as a drop-down list. The first parameter in the list will be activated by default 'boolean' is rendered as a checkbox. The resulting parameter will be either 'true' or 'false' 'string' allows any characters 'number' allows only numbers 'password' is rendered as a password field (the characters are replaced with *'s when being types. This parameter is not passed through to the plugin. It is instead inserted directly into the password cache keyed on the instance name. The value of the parameter 'bindPWPrompt' (see example below) is set to the key. In addition to the configurable parameters, the following magic parameters may be defined: HELP_TOKEN;helptoken - a pointer to the online manual section for this plugin HELP_TEXT;helptext - a general help string describing the plugin For example: "username;string;The username you wish to login as" "bindPWPrompt;password;Enter password to bind as above user with" "algorithm;choice(RSA,DSA);Which algorithm do you want to use" "enable;boolean;Do you want to run this plugin" "port;number;Which port number do you want to use" - Specified by:
getExtendedPluginInfo
in interfaceIExtendedPluginInfo
-
init
public void init(PublisherProcessor processor, IConfigStore config) throws EBaseException
Description copied from interface:ILdapRule
Initialize the plugin.- Specified by:
init
in interfaceILdapRule
- Throws:
EBaseException
- Initialization failed.
-
init
public void init(IConfigStore config) throws EBaseException
The init method in ILdapPlugin It can not set set mapper,publisher choice for console dynamicly Should not use this method to init.- Specified by:
init
in interfaceILdapPlugin
- Parameters:
config
- the configuration store to initialize from.- Throws:
ELdapException
- initialization failed due to Ldap error.EBaseException
- initialization failed.
-
getImplName
public java.lang.String getImplName()
Returns the implementation name.- Specified by:
getImplName
in interfaceILdapRule
-
getDescription
public java.lang.String getDescription()
Returns the description of the ldap publisher.- Specified by:
getDescription
in interfaceILdapRule
-
setInstanceName
public void setInstanceName(java.lang.String insName)
Set the instance name- Specified by:
setInstanceName
in interfaceILdapRule
-
getInstanceName
public java.lang.String getInstanceName()
Returns the instance name- Specified by:
getInstanceName
in interfaceILdapRule
-
getInstanceParams
public java.util.Vector<java.lang.String> getInstanceParams()
Returns the current instance parameters.- Specified by:
getInstanceParams
in interfaceILdapRule
-
setPredicate
public void setPredicate(ILdapExpression exp)
Sets a predicate expression for rule matching.- Parameters:
exp
- The predicate expression for the rule.
-
getPredicate
public ILdapExpression getPredicate()
Returns the predicate expression for the rule.- Returns:
- The predicate expression for the rule.
-
getMapper
public java.lang.String getMapper()
-
getPublisher
public java.lang.String getPublisher()
-
getType
public java.lang.String getType()
-
enabled
public boolean enabled()
Description copied from interface:ILdapRule
Returns true if the rule is enabled, false if it's disabled.
-
getDefaultParams
public java.util.Vector<java.lang.String> getDefaultParams()
Returns the initial default parameters.- Specified by:
getDefaultParams
in interfaceILdapRule
-
-