|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectcom.sun.slamd.scripting.engine.Variable
com.sun.slamd.scripting.ldap.LDAPModificationVariable
This class defines a variable intended to store an LDAP modification. LDAP modifications have the following methods:
| Field Summary | |
static java.lang.String |
ADD_VALUE_METHOD_NAME
The name of the method that will be used to add a new value to this modification. |
static int |
ADD_VALUE_METHOD_NUMBER
The method number for the "addValue" method. |
static int |
ASSIGN_1_METHOD_NUMBER
The method number for the first "assign" method. |
static int |
ASSIGN_2_METHOD_NUMBER
The method number for the second "assign" method. |
static int |
ASSIGN_3_METHOD_NUMBER
The method number for the third "assign" method. |
static java.lang.String |
ASSIGN_METHOD_NAME
The name of the method that will be used to initialize this LDAP modification. |
static java.lang.String |
GET_MOD_TYPE_METHOD_NAME
The name of the method that will be used to retrieve the modification type for this modification. |
static int |
GET_MOD_TYPE_METHOD_NUMBER
The method number for the "getModType" method. |
static java.lang.String |
GET_NAME_METHOD_NAME
The name of the method that will be used to get the name of the LDAP attribute. |
static int |
GET_NAME_METHOD_NUMBER
The method number for the "getName" method. |
static java.lang.String |
GET_VALUES_METHOD_NAME
The name of the method that will be used to get the set of values for the LDAP attribute. |
static int |
GET_VALUES_METHOD_NUMBER
The method number for the "getValues" method. |
static java.lang.String |
IS_NULL_METHOD_NAME
The name of the method that will be used to determine whether this LDAP modification has been initialized. |
static int |
IS_NULL_METHOD_NUMBER
The method number for the "isNull" method. |
static Method[] |
LDAP_MODIFICATION_VARIABLE_METHODS
The set of methods associated with LDAP modification variables. |
static java.lang.String |
LDAP_MODIFICATION_VARIABLE_TYPE
The name that will be used for the data type of LDAP modification variables. |
static java.lang.String |
MOD_TYPE_ADD_METHOD_NAME
The name of the method that will be used to retrieve the modification type to use when adding new a attribute or values. |
static int |
MOD_TYPE_ADD_METHOD_NUMBER
The method number for the "modTypeAdd" method. |
static java.lang.String |
MOD_TYPE_DELETE_METHOD_NAME
The name of the method that will be used to retrieve the modification type to use when removing an attribute or values. |
static int |
MOD_TYPE_DELETE_METHOD_NUMBER
The method number for the "modTypeDelete" method. |
static java.lang.String |
MOD_TYPE_REPLACE_METHOD_NAME
The name of the method that will be used to retrieve the modification type to use when replacing attribute values. |
static int |
MOD_TYPE_REPLACE_METHOD_NUMBER
The method number for the "modTypeReplace" method. |
| Constructor Summary | |
LDAPModificationVariable()
Creates a new variable with no name, to be used only when creating a variable with Class.newInstance(), and only when
setName() is called after that to set the name. |
|
| Method Summary | |
void |
addValue(java.lang.String value)
Adds the provided attribute value to the modification as long as it does not already exist. |
void |
assign(Argument argument)
Assigns the value of the provided argument to this variable. |
Variable |
executeMethod(int lineNumber,
int methodNumber,
Argument[] arguments)
Executes the specified method, using the provided variables as arguments to the method, and makes the return value available to the caller. |
java.lang.String |
getAttributeName()
Retrieves the name of the LDAP attribute associated with this modification. |
java.lang.String[] |
getAttributeValues()
Retrieves the set of values for the LDAP attribute associated with this modification. |
int |
getMethodNumber(java.lang.String methodName,
java.lang.String[] argumentTypes)
Retrieves the method number for the method that has the specified name and argument types, or -1 if there is no such method. |
Method[] |
getMethods()
Retrieves a list of all methods defined for this variable. |
java.lang.String |
getReturnTypeForMethod(java.lang.String methodName,
java.lang.String[] argumentTypes)
Retrieves the return type for the method with the specified name and argument types. |
java.lang.String |
getValueAsString()
Retrieves a string representation of the value of this argument. |
java.lang.String |
getVariableTypeName()
Retrieves the name of the variable type for this variable. |
boolean |
hasMethod(java.lang.String methodName)
Indicates whether this variable type has a method with the specified name. |
void |
setAttributeName(java.lang.String attributeName)
Specifies the name for the LDAP attribute associated with this modification. |
void |
setAttributeValues(java.lang.String[] values)
Specifies the set of values for the LDAP attribute associated with this modification. |
netscape.ldap.LDAPModification |
toLDAPModification()
Retrieves this modification as an LDAPModification object. |
| Methods inherited from class com.sun.slamd.scripting.engine.Variable |
getArgumentAsString, getArgumentType, getArgumentValue, getName, getStatTrackers, isValidIdentifier, setName, startStatTrackers, stopStatTrackers |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
public static final java.lang.String LDAP_MODIFICATION_VARIABLE_TYPE
public static final java.lang.String ADD_VALUE_METHOD_NAME
public static final int ADD_VALUE_METHOD_NUMBER
public static final java.lang.String ASSIGN_METHOD_NAME
public static final int ASSIGN_1_METHOD_NUMBER
public static final int ASSIGN_2_METHOD_NUMBER
public static final int ASSIGN_3_METHOD_NUMBER
public static final java.lang.String GET_MOD_TYPE_METHOD_NAME
public static final int GET_MOD_TYPE_METHOD_NUMBER
public static final java.lang.String GET_NAME_METHOD_NAME
public static final int GET_NAME_METHOD_NUMBER
public static final java.lang.String GET_VALUES_METHOD_NAME
public static final int GET_VALUES_METHOD_NUMBER
public static final java.lang.String IS_NULL_METHOD_NAME
public static final int IS_NULL_METHOD_NUMBER
public static final java.lang.String MOD_TYPE_ADD_METHOD_NAME
public static final int MOD_TYPE_ADD_METHOD_NUMBER
public static final java.lang.String MOD_TYPE_DELETE_METHOD_NAME
public static final int MOD_TYPE_DELETE_METHOD_NUMBER
public static final java.lang.String MOD_TYPE_REPLACE_METHOD_NAME
public static final int MOD_TYPE_REPLACE_METHOD_NUMBER
public static final Method[] LDAP_MODIFICATION_VARIABLE_METHODS
| Constructor Detail |
public LDAPModificationVariable()
Class.newInstance(), and only when
setName() is called after that to set the name.
| Method Detail |
public java.lang.String getAttributeName()
public void setAttributeName(java.lang.String attributeName)
attributeName - The name for the LDAP attribute associated with this
modification.public java.lang.String[] getAttributeValues()
public void setAttributeValues(java.lang.String[] values)
values - The set of values for the LDAP attribute associated with
this modification.public void addValue(java.lang.String value)
value - The attribute value to add to this modification.public netscape.ldap.LDAPModification toLDAPModification()
public java.lang.String getVariableTypeName()
getVariableTypeName in class Variablepublic Method[] getMethods()
getMethods in class Variablepublic boolean hasMethod(java.lang.String methodName)
hasMethod in class VariablemethodName - The name of the method.
true if this variable has a method with the specified
name, or false if it does not.
public int getMethodNumber(java.lang.String methodName,
java.lang.String[] argumentTypes)
getMethodNumber in class VariablemethodName - The name of the method.argumentTypes - The list of argument types for the method.
public java.lang.String getReturnTypeForMethod(java.lang.String methodName,
java.lang.String[] argumentTypes)
getReturnTypeForMethod in class VariablemethodName - The name of the method.argumentTypes - The set of argument types for the method.
null if there is
no such method defined.
public Variable executeMethod(int lineNumber,
int methodNumber,
Argument[] arguments)
throws ScriptException
executeMethod in class VariablelineNumber - The line number of the script in which the method
call occurs.methodNumber - The method number of the method to execute.arguments - The set of arguments to use for the method.
null if it
does not return a value.
ScriptException - If the specified method does not exist, or if a
problem occurs while attempting to execute it.
public void assign(Argument argument)
throws ScriptException
assign in class Variableargument - The argument whose value should be assigned to this
variable.
ScriptException - If a problem occurs while performing the
assignment.public java.lang.String getValueAsString()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||