|
All LDAP Classes Internal LDAP Classes |
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectcom.novell.ldap.LDAPControl
public class LDAPControl
Encapsulates optional additional parameters or constraints to be applied to an LDAP operation.
When included with LDAPConstraints or LDAPSearchConstraints on an LDAPConnection or with a specific operation request, it is sent to the server along with operation requests.
LDAPConnection.getResponseControls()
,
LDAPConstraints.getControls()
,
LDAPConstraints.setControls(com.novell.ldap.LDAPControl)
,
Serialized FormField Summary | |
---|---|
private RfcControl |
control
|
private static RespControlVector |
registeredControls
|
Constructor Summary | |
---|---|
|
LDAPControl()
This constructor was added to support default Serialization |
protected |
LDAPControl(RfcControl control)
Create an LDAPControl from an existing control. |
|
LDAPControl(java.lang.String oid,
boolean critical,
byte[] values)
Constructs a new LDAPControl object using the specified values. |
Method Summary | |
---|---|
java.lang.Object |
clone()
Returns a copy of the current LDAPControl object. |
(package private) RfcControl |
getASN1Object()
Returns the RFC 2251 Control object. |
java.lang.String |
getID()
Returns the identifier of the control. |
(package private) static RespControlVector |
getRegisteredControls()
|
byte[] |
getValue()
Returns the control-specific data of the object. |
(package private) static LDAPXMLHandler |
getXMLHandler(java.lang.String tagname,
LDAPXMLHandler parenthandler)
This method return the LDAPHandler which handles the XML (DSML) tags for this class |
boolean |
isCritical()
Returns whether the control is critical for the operation. |
(package private) void |
newLine(int indentTabs,
java.io.Writer out)
|
static java.lang.Object |
readDSML(java.io.InputStream input)
This method is used to deserialize the DSML encoded representation of this class. |
void |
readExternal(java.io.ObjectInput in)
Reads the serialized object from the underlying input stream. |
static void |
register(java.lang.String oid,
java.lang.Class controlClass)
Registers a class to be instantiated on receipt of a control with the given OID. |
protected void |
setValue(byte[] controlValue)
Sets the control-specific data of the object. |
java.lang.String |
toString()
Returns a string representation of this class. |
void |
writeDSML(java.io.OutputStream oout)
This method does DSML serialization of the instance. |
void |
writeExternal(java.io.ObjectOutput out)
Writes the object state to a stream in XML format |
Methods inherited from class java.lang.Object |
---|
equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
private static RespControlVector registeredControls
private RfcControl control
Constructor Detail |
---|
public LDAPControl()
public LDAPControl(java.lang.String oid, boolean critical, byte[] values)
oid
- The OID of the control, as a dotted string.
critical
- True if the LDAP operation should be discarded if
the control is not supported. False if
the operation can be processed without the control.
values
- The control-specific data.protected LDAPControl(RfcControl control)
Method Detail |
---|
public java.lang.Object clone()
clone
in class java.lang.Object
public java.lang.String getID()
public byte[] getValue()
protected void setValue(byte[] controlValue)
public boolean isCritical()
public static void register(java.lang.String oid, java.lang.Class controlClass)
Any previous registration for the OID is overridden. The controlClass must be an extension of LDAPControl.
oid
- The object identifier of the control.
controlClass
- A class which can instantiate an LDAPControl.static RespControlVector getRegisteredControls()
final RfcControl getASN1Object()
void newLine(int indentTabs, java.io.Writer out) throws java.io.IOException
java.io.IOException
public void writeDSML(java.io.OutputStream oout) throws java.io.IOException
oout
- Outputstream where the serialzed data has to be written
java.io.IOException
- if write fails on OutputStreampublic static java.lang.Object readDSML(java.io.InputStream input) throws java.io.IOException
input
- InputStream for the DSML formatted data.
java.io.IOException
- when serialization fails.static LDAPXMLHandler getXMLHandler(java.lang.String tagname, LDAPXMLHandler parenthandler)
tagname
- Name of the Root tag used to represent this class.parenthandler
- Parent LDAPXMLHandler for this tag.
public java.lang.String toString()
toString
in class java.lang.Object
public void writeExternal(java.io.ObjectOutput out) throws java.io.IOException
writeExternal
in interface java.io.Externalizable
out
- The ObjectOutput stream where the Object in XML format
is being written to
java.io.IOException
- - If I/O errors occurpublic void readExternal(java.io.ObjectInput in) throws java.io.IOException, java.lang.ClassNotFoundException
readExternal
in interface java.io.Externalizable
in
- The ObjectInput stream where the Serialized Object is being read from
java.io.IOException
- - If I/O errors occur
java.lang.ClassNotFoundException
- - If the class for an object being restored
cannot be found.
|
All LDAP Classes Internal LDAP Classes |
||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |