Class LdapDecoder
- java.lang.Object
-
- org.apache.directory.api.ldap.codec.api.LdapDecoder
-
public class LdapDecoder extends Object
The LdapDecoder decodes ASN.1 BER encoded PDUs into LDAP messages- Author:
- Apache Directory Project
-
-
Field Summary
Fields Modifier and Type Field Description static String
MAX_PDU_SIZE_ATTR
The maximum PDU size, stored into the LDAPSession's attributestatic String
MESSAGE_CONTAINER_ATTR
The name of the LdapSession's attribute for the LDAP container used during the decoding
-
Constructor Summary
Constructors Constructor Description LdapDecoder()
Creates an instance of a Ldap Decoder implementation.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Message
decode(InputStream in, LdapMessageContainer<MessageDecorator<? extends Message>> container)
Decodes a PDU from an input stream into a Ldap message container.
-
-
-
Field Detail
-
MESSAGE_CONTAINER_ATTR
public static final String MESSAGE_CONTAINER_ATTR
The name of the LdapSession's attribute for the LDAP container used during the decoding- See Also:
- Constant Field Values
-
MAX_PDU_SIZE_ATTR
public static final String MAX_PDU_SIZE_ATTR
The maximum PDU size, stored into the LDAPSession's attribute- See Also:
- Constant Field Values
-
-
Constructor Detail
-
LdapDecoder
public LdapDecoder()
Creates an instance of a Ldap Decoder implementation.
-
-
Method Detail
-
decode
public Message decode(InputStream in, LdapMessageContainer<MessageDecorator<? extends Message>> container) throws DecoderException
Decodes a PDU from an input stream into a Ldap message container. We can only decode one complete message.- Parameters:
in
- The input stream to read and decode PDU bytes fromcontainer
- The LdapMessageContainer containing the message to decode- Returns:
- return The decoded message
- Throws:
DecoderException
- If the decoding failed
-
-