Class SortRequestFactory
- java.lang.Object
-
- org.apache.directory.api.ldap.codec.api.AbstractControlFactory<SortRequest>
-
- org.apache.directory.api.ldap.codec.controls.sort.SortRequestFactory
-
- All Implemented Interfaces:
ControlFactory<SortRequest>
public class SortRequestFactory extends AbstractControlFactory<SortRequest>
AControlFactory
for SortRequestControl.- Version:
- $Rev$, $Date$
- Author:
- Apache Directory Project
-
-
Field Summary
Fields Modifier and Type Field Description static int
ORDERING_RULE_TAG
ASN.1 BER tag for the forward ordering rulestatic int
REVERSE_ORDER_TAG
ASN.1 BER tag for the backward ordering rule
-
Constructor Summary
Constructors Constructor Description SortRequestFactory(LdapApiService codec)
Creates a new instance of SortRequestFactory.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
decodeValue(Control control, byte[] controlBytes)
Decode a Control's value.void
encodeValue(Asn1Buffer buffer, Control control)
Encode the value part of the control.SortRequest
newControl()
Creates and returns a version of the Control.-
Methods inherited from class org.apache.directory.api.ldap.codec.api.AbstractControlFactory
decodeValue, getOid
-
-
-
-
Field Detail
-
ORDERING_RULE_TAG
public static final int ORDERING_RULE_TAG
ASN.1 BER tag for the forward ordering rule- See Also:
- Constant Field Values
-
REVERSE_ORDER_TAG
public static final int REVERSE_ORDER_TAG
ASN.1 BER tag for the backward ordering rule- See Also:
- Constant Field Values
-
-
Constructor Detail
-
SortRequestFactory
public SortRequestFactory(LdapApiService codec)
Creates a new instance of SortRequestFactory.- Parameters:
codec
- The LDAP codec.
-
-
Method Detail
-
newControl
public SortRequest newControl()
Creates and returns a version of the Control.- Returns:
- The
CodecControl
decorated version of the Control.
-
encodeValue
public void encodeValue(Asn1Buffer buffer, Control control)
Encode the value part of the control.- Specified by:
encodeValue
in interfaceControlFactory<SortRequest>
- Overrides:
encodeValue
in classAbstractControlFactory<SortRequest>
- Parameters:
buffer
- The buffer into which to put the encoded valuecontrol
- The control to encode
-
decodeValue
public void decodeValue(Control control, byte[] controlBytes) throws DecoderException
Decode a Control's value. It will feed the Control.- Specified by:
decodeValue
in interfaceControlFactory<SortRequest>
- Overrides:
decodeValue
in classAbstractControlFactory<SortRequest>
- Parameters:
control
- The control to feedcontrolBytes
- The data to decode- Throws:
DecoderException
- If the value can't be decoded
-
-