|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectorg.apache.directory.shared.asn1.AbstractAsn1Object
org.apache.directory.shared.ldap.codec.ControlCodec
public class ControlCodec
A Asn1Object to store a Control.
| Field Summary |
|---|
| Fields inherited from class org.apache.directory.shared.asn1.AbstractAsn1Object |
|---|
parent |
| Constructor Summary | |
|---|---|
ControlCodec()
Default constructor. |
|
| Method Summary | |
|---|---|
int |
computeLength()
Compute the Control length Control : 0x30 L1 | +--> 0x04 L2 controlType [+--> 0x01 0x01 criticality] [+--> 0x04 L3 controlValue] Control length = Length(0x30) + length(L1) + Length(0x04) + Length(L2) + L2 [+ Length(0x01) + 1 + 1] [+ Length(0x04) + Length(L3) + L3] |
java.nio.ByteBuffer |
encode(java.nio.ByteBuffer buffer)
Generate the PDU which contains the Control. |
java.lang.String |
getControlType()
Get the control type |
java.lang.Object |
getControlValue()
Get the control value |
boolean |
getCriticality()
Get the criticality |
byte[] |
getEncodedValue()
Get the raw control encoded bytes |
void |
setControlType(java.lang.String controlType)
Set the control type |
void |
setControlValue(java.lang.Object controlValue)
Set the control value |
void |
setCriticality(boolean criticality)
Set the criticality |
void |
setEncodedValue(byte[] encodedValue)
Set the encoded control value |
java.lang.String |
toString()
Return a String representing a Control |
| Methods inherited from class org.apache.directory.shared.asn1.AbstractAsn1Object |
|---|
addLength, getCurrentLength, getExpectedLength, getParent, getTlvId, setCurrentLength, setExpectedLength, setParent |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public ControlCodec()
| Method Detail |
|---|
public java.lang.String getControlType()
public void setControlType(java.lang.String controlType)
controlType - The OID to be storedpublic java.lang.Object getControlValue()
public void setEncodedValue(byte[] encodedValue)
encodedValue - The encoded control value to storepublic byte[] getEncodedValue()
public void setControlValue(java.lang.Object controlValue)
controlValue - The control value to storepublic boolean getCriticality()
true if the criticality flag is true.public void setCriticality(boolean criticality)
criticality - The criticality valuepublic int computeLength()
computeLength in interface Asn1ObjectcomputeLength in class AbstractAsn1Object
public java.nio.ByteBuffer encode(java.nio.ByteBuffer buffer)
throws EncoderException
encode in interface Asn1Objectencode in class AbstractAsn1Objectbuffer - The encoded PDU
EncoderException - If anything goes wrong.public java.lang.String toString()
toString in class java.lang.Object
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||