Class TriggerSpecificationParser
java.lang.Object
org.apache.directory.api.ldap.trigger.TriggerSpecificationParser
A parser for a TriggerSpecification.
Here is the grammar:
triggerSpecification = ( SP )* "after" ( SP )+ ldapOperationSPCalls
ldapOperationSPCalls =
addOperationCalls |
deleteOperationCalls |
modifyOperationCalls |
modifyDNOperationCalls
--------------------------------------------
addOperationCalls =
"add" ( SP )+
(
callNameOptionList
OPEN_PAREN ( SP )*
( addParameterList )?
CLOSE_PAREN ( SP )* SEMI ( SP )*
)+
addParamList ::=
addParameter ( SP )* ( SEP ( SP )* addParameter ( SP )* )*
addParameter ::= "$entry" | "$attributes" | "$ldapcontext" ( SP )+ DN | "$operationprincipal"
--------------------------------------------
deleteOperationCalls =
"delete" ( SP )
(
callNameOptionList
OPEN_PAREN ( SP )*
( deleteParameterList )?
CLOSE_PAREN ( SP )* SEMI ( SP )*
)+
deleteParameterList =
deleteParameter ( SP )*
( SEP ( SP )* deleteParameter ( SP )* )*
deleteParameter =
"$name" | "$deletedentry" | "$ldapcontext" ( SP )+ DN | "$operationprincipal"
--------------------------------------------
modifyOperationCalls =
"modify" ( SP )+
(
callNameOptionList
OPEN_PAREN ( SP )*
( modifyParameterList )?
CLOSE_PAREN ( SP )* SEMI ( SP )*
)+
modifyParameterList =
modifyParameter ( SP )*
( SEP ( SP )* modifyParameter ( SP )* )*
modifyParameter =
"$object" | "$modification"| "$oldentry" | "$newentry" | "$ldapcontext" ( SP )+ DN | "$operationprincipal"
--------------------------------------------
modifyDNOperationCalls =
"modify" DOT ( "rename" | "export" | "import" )
(
( SP )+ callNameOptionList
OPEN_PAREN ( SP )*
( modifyDNSPParameterList )?
CLOSE_PAREN ( SP )* SEMI ( SP )*
)+
modifyDNParameterList =
modifyDNParameter ( SP )*
( SEP ( SP )* modifyDNParameter ( SP )* )*
modifyDNParameter =
"$entry" | "$newrdn" | "$deleteoldrdn" | "$newSuperior" | "$oldRdn" |
"$oldSuperiorDn" | "$newDn" | "$ldapcontext" ( SP )+ DN | "$operationprincipal"
--------------------------------------------
callNameOptionList =
"call" ( SP )+ quotedUtf8String ( SP )*
( genericOptionList ( SP )* )?
genericOptionList =
OPEN_CURLY
( SP )*
(
genericOption ( SP )*
(
SEP ( SP )* genericOption ( SP )*
)*
)*
CLOSE_CURLY
genericOption =
(
"languagescheme" ( SP )+ QuotedUTF8String
|
"searchcontext" ( SP )+
(
OPEN_CURLY ( SP )*
( "scope" ( SP )+ ( "base" | "one" | "subtree" ) ( SP )* )?
CLOSE_CURLY ( SP )+
)?
DN
)
- Author:
- Apache Directory Project
-
Constructor Summary
ConstructorsConstructorDescriptionCreates a TriggerSpecification parser.TriggerSpecificationParser(org.apache.directory.api.ldap.model.schema.NormalizerMappingResolver<org.apache.directory.api.ldap.model.schema.Normalizer> resolver) Creates a normalizing TriggerSpecification parser.TriggerSpecificationParser(org.apache.directory.api.ldap.model.schema.SchemaManager schemaManager) Creates a TriggerSpecification parser. -
Method Summary
Modifier and TypeMethodDescriptionbooleanTests to see if this parser is normalizing.Parses an TriggerSpecification without exhausting the parser.
-
Constructor Details
-
TriggerSpecificationParser
public TriggerSpecificationParser()Creates a TriggerSpecification parser. -
TriggerSpecificationParser
public TriggerSpecificationParser(org.apache.directory.api.ldap.model.schema.SchemaManager schemaManager) Creates a TriggerSpecification parser.- Parameters:
schemaManager- The SchemaManager
-
TriggerSpecificationParser
public TriggerSpecificationParser(org.apache.directory.api.ldap.model.schema.NormalizerMappingResolver<org.apache.directory.api.ldap.model.schema.Normalizer> resolver) Creates a normalizing TriggerSpecification parser.- Parameters:
resolver- the resolver
-
-
Method Details
-
parse
Parses an TriggerSpecification without exhausting the parser.- Parameters:
spec- the specification to be parsed- Returns:
- the specification instance
- Throws:
ParseException- if there is any syntax error
-
isNormalizing
public boolean isNormalizing()Tests to see if this parser is normalizing.- Returns:
- true if it normalizes false otherwise
-