public interface OperationContext
Modifier and Type | Method and Description |
---|---|
void |
add(org.apache.directory.shared.ldap.entry.ServerEntry entry,
Collection<String> byPass) |
void |
addRequestControl(org.apache.directory.shared.ldap.message.control.Control requestControl)
Adds a request control to this operation.
|
void |
addRequestControls(org.apache.directory.shared.ldap.message.control.Control[] requestControls)
Adds many request controls to this operation.
|
void |
addResponseControl(org.apache.directory.shared.ldap.message.control.Control responseControl)
Adds a response control to this operation.
|
void |
delete(org.apache.directory.shared.ldap.name.DN dn,
Collection<String> byPass) |
Collection<String> |
getByPassed()
Gets the set of bypassed Interceptors.
|
org.apache.directory.shared.ldap.name.DN |
getDn() |
LdapPrincipal |
getEffectivePrincipal()
Gets the effective principal for this operation which may not be the
same as the authenticated principal when the session for this context
has an explicit authorization id, or this operation was applied with
the proxy authorization control.
|
ClonedServerEntry |
getEntry()
Gets the server entry associated with the target DN of this
OperationContext.
|
OperationContext |
getFirstOperation()
Gets the first, direct operation issued against the DirectoryService.
|
OperationContext |
getLastOperation()
Gets the last, operation issued on the DirectoryService.
|
String |
getName() |
OperationContext |
getNextOperation()
Gets the next, indirect operation issued on the DirectoryService.
|
OperationContext |
getPreviousOperation()
Gets the previous, operation issued on the DirectoryService.
|
org.apache.directory.shared.ldap.message.control.Control |
getRequestControl(String numericOid)
Gets a request control if present for this request.
|
org.apache.directory.shared.ldap.message.control.Control |
getResponseControl(String numericOid)
Gets a response control if present for this request.
|
int |
getResponseControlCount()
Checks the number of response controls have been generated for this operation.
|
org.apache.directory.shared.ldap.message.control.Control[] |
getResponseControls()
Gets all the response controls producted during this operation.
|
CoreSession |
getSession()
Gets the session associated with this operation.
|
boolean |
hasBypass()
Checks to see if any Interceptors are bypassed by this Invocation.
|
boolean |
hasEntry(org.apache.directory.shared.ldap.name.DN dn,
Collection<String> byPass)
Checks to see if an entry exists.
|
boolean |
hasRequestControl(String numericOid)
Checks to see if a request control is present on this request.
|
boolean |
hasRequestControls()
Checks if any request controls exists for this operation.
|
boolean |
hasResponseControl(String numericOid)
Checks to see if a response control is present on this operation.
|
boolean |
hasResponseControls()
Checks if any response controls have been generated for this operation.
|
void |
ignoreReferral()
Set the throwReferral flag to false
|
boolean |
isBypassed(String interceptorName)
Checks to see if an Interceptor is bypassed for this operation.
|
boolean |
isFirstOperation()
Checks to see if this operation is the first operation in a chain of
operations performed on the DirectoryService.
|
boolean |
isReferralIgnored() |
boolean |
isReferralThrown() |
ClonedServerEntry |
lookup(org.apache.directory.shared.ldap.name.DN dn,
Collection<String> byPass) |
ClonedServerEntry |
lookup(LookupOperationContext lookupContext) |
void |
modify(org.apache.directory.shared.ldap.name.DN dn,
List<org.apache.directory.shared.ldap.entry.Modification> mods,
Collection<String> byPass) |
LookupOperationContext |
newLookupContext(org.apache.directory.shared.ldap.name.DN dn) |
void |
setByPassed(Collection<String> byPassed)
Sets the set of bypassed Interceptors.
|
void |
setDn(org.apache.directory.shared.ldap.name.DN dn)
Set the context DN
|
void |
setEntry(ClonedServerEntry entry)
Sets the server entry associated with the target DN of this
OperationContext.
|
void |
throwReferral()
Set the throwReferral flag to true
|
boolean isFirstOperation()
OperationContext getFirstOperation()
OperationContext getPreviousOperation()
OperationContext getNextOperation()
OperationContext getLastOperation()
LdapPrincipal getEffectivePrincipal()
CoreSession.getAuthenticatedPrincipal()
,
CoreSession.getEffectivePrincipal()
org.apache.directory.shared.ldap.name.DN getDn()
void setDn(org.apache.directory.shared.ldap.name.DN dn)
dn
- The DN to setClonedServerEntry getEntry()
ClonedServerEntry.getOriginalEntry()
. The return value may be
null in which case any lookup performed to access it may set it to
prevent the need for subsequent lookups.
Also note that during the course of handling some operations such as
those that rename, move or rename and move the entry, may alter the DN
of this entry. Interceptor implementors should not presume the DN or
the values contained in this entry are currently what is present in the
DIT. The original entry contained in the ClonedServerEntry shoudl be
used as the definitive source of information about the state of the
entry in the DIT before returning from the Partition subsystem.void setEntry(ClonedServerEntry entry)
entry
- the entry whose DN is associated with this OperationContext.void addResponseControl(org.apache.directory.shared.ldap.message.control.Control responseControl)
responseControl
- the response control to add to this operationboolean hasResponseControl(String numericOid)
numericOid
- the numeric OID of the control also known as it's type OIDorg.apache.directory.shared.ldap.message.control.Control getResponseControl(String numericOid)
numericOid
- the numeric OID of the control also known as it's type OIDorg.apache.directory.shared.ldap.message.control.Control[] getResponseControls()
boolean hasResponseControls()
int getResponseControlCount()
void addRequestControl(org.apache.directory.shared.ldap.message.control.Control requestControl)
requestControl
- the request control to add to this operationboolean hasRequestControl(String numericOid)
numericOid
- the numeric OID of the control also known as it's type OIDboolean hasRequestControls()
org.apache.directory.shared.ldap.message.control.Control getRequestControl(String numericOid)
numericOid
- the numeric OID of the control also known as it's type OIDvoid addRequestControls(org.apache.directory.shared.ldap.message.control.Control[] requestControls)
requestControls
- the request controls to add to this operationString getName()
boolean isBypassed(String interceptorName)
interceptorName
- the interceptorName of the Interceptor to check for bypassboolean hasBypass()
Collection<String> getByPassed()
void setByPassed(Collection<String> byPassed)
byPassed
- the set of bypassed InterceptorsCoreSession getSession()
LookupOperationContext newLookupContext(org.apache.directory.shared.ldap.name.DN dn)
ClonedServerEntry lookup(org.apache.directory.shared.ldap.name.DN dn, Collection<String> byPass) throws Exception
Exception
ClonedServerEntry lookup(LookupOperationContext lookupContext) throws Exception
Exception
void modify(org.apache.directory.shared.ldap.name.DN dn, List<org.apache.directory.shared.ldap.entry.Modification> mods, Collection<String> byPass) throws Exception
Exception
void add(org.apache.directory.shared.ldap.entry.ServerEntry entry, Collection<String> byPass) throws Exception
Exception
void delete(org.apache.directory.shared.ldap.name.DN dn, Collection<String> byPass) throws Exception
Exception
boolean hasEntry(org.apache.directory.shared.ldap.name.DN dn, Collection<String> byPass) throws Exception
dn
- the distinguished name of the entry to checkbyPass
- collection of Interceptor
's to bypass for this checkException
- on failure to perform this operationvoid throwReferral()
boolean isReferralThrown()
true
if the referrals are thrownvoid ignoreReferral()
boolean isReferralIgnored()
true
if the referrals are ignoredCopyright © 2003–2015 The Apache Software Foundation. All rights reserved.