E
- public abstract class ControlDecorator<E extends Control> extends AbstractAsn1Object implements CodecControl<E>
Modifier and Type | Field and Description |
---|---|
protected byte[] |
value
The encoded value of the control.
|
protected int |
valueLength
The encoded value length
|
Constructor and Description |
---|
ControlDecorator(LdapApiService codec,
E decoratedControl)
Creates a ControlDecorator to codec enable it.
|
Modifier and Type | Method and Description |
---|---|
int |
computeLength()
Compute the object length, which is the sum of all inner length.
|
boolean |
equals(Object o) |
LdapApiService |
getCodecService()
Gets the codec service responsible for managing the encoding and
decoding of the decorated objects.
|
E |
getDecorated()
Gets the object being decorated by this IDecorator.
|
String |
getOid()
Get the OID
|
byte[] |
getValue()
Get the control value
|
int |
hashCode() |
boolean |
hasValue()
Checks to see if a value is set for this
CodecControl . |
boolean |
isCritical()
Get the criticality
|
void |
setCritical(boolean criticality)
Set the criticality
|
void |
setDecorated(E decorated) |
void |
setValue(byte[] value)
Set the encoded control value
|
String |
toString()
Return a String representing a Control
|
addLength, encode, getCurrentLength, getExpectedLength, getParent, getTlvId, setCurrentLength, setExpectedLength, setParent
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
decode
protected int valueLength
protected byte[] value
public ControlDecorator(LdapApiService codec, E decoratedControl)
decoratedControl
- The Control to decorate.public E getDecorated()
getDecorated
in interface Decorator<E extends Control>
public void setDecorated(E decorated)
public LdapApiService getCodecService()
getCodecService
in interface Decorator<E extends Control>
public boolean hasValue()
CodecControl
.hasValue
in interface CodecControl<E extends Control>
public byte[] getValue()
getValue
in interface CodecControl<E extends Control>
public void setValue(byte[] value)
setValue
in interface CodecControl<E extends Control>
value
- The encoded control value to storepublic boolean isCritical()
isCritical
in interface Control
true
if the criticality flag is true.public void setCritical(boolean criticality)
setCritical
in interface Control
criticality
- The criticality valuepublic int computeLength()
computeLength
in interface Asn1Object
computeLength
in interface Decorator<E extends Control>
computeLength
in class AbstractAsn1Object
public int hashCode()
hashCode
in class Object
Object.hashCode()
public boolean equals(Object o)
equals
in class Object
Object.equals(Object)
Copyright © 2003-2014 The Apache Software Foundation. All Rights Reserved.