org.apache.directory.shared.ldap.codec.bind
Class SimpleAuthentication

java.lang.Object
  extended byorg.apache.directory.shared.asn1.Asn1Object
      extended byorg.apache.directory.shared.ldap.codec.bind.LdapAuthentication
          extended byorg.apache.directory.shared.ldap.codec.bind.SimpleAuthentication

public class SimpleAuthentication
extends LdapAuthentication

A ldapObject which stores the Simple authentication for a BindRequest.

Author:
Apache Directory Project

Field Summary
 
Fields inherited from class org.apache.directory.shared.asn1.Asn1Object
parent
 
Constructor Summary
SimpleAuthentication()
           
 
Method Summary
 int computeLength()
          Compute the Simple authentication length Simple authentication : 0x80 L1 simple L1 = Length(simple) Length(Simple authentication) = Length(0x80) + Length(L1) + Length(simple)
 java.nio.ByteBuffer encode(java.nio.ByteBuffer buffer)
          Encode the simple authentication to a PDU.
 byte[] getSimple()
          Get the simple password
 void setSimple(byte[] simple)
          Set the simple password
 java.lang.String toString()
          Return the simple authentication as a string
 
Methods inherited from class org.apache.directory.shared.asn1.Asn1Object
addLength, getCurrentLength, getExpectedLength, getParent, setCurrentLength, setExpectedLength, setParent
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

SimpleAuthentication

public SimpleAuthentication()
Method Detail

getSimple

public byte[] getSimple()
Get the simple password

Returns:
The password

setSimple

public void setSimple(byte[] simple)
Set the simple password

Parameters:
simple - The simple password

computeLength

public int computeLength()
Compute the Simple authentication length Simple authentication : 0x80 L1 simple L1 = Length(simple) Length(Simple authentication) = Length(0x80) + Length(L1) + Length(simple)


encode

public java.nio.ByteBuffer encode(java.nio.ByteBuffer buffer)
                           throws org.apache.directory.shared.asn1.codec.EncoderException
Encode the simple authentication to a PDU. SimpleAuthentication : 0x80 LL simple

Parameters:
buffer - The buffer where to put the PDU
Returns:
The PDU.
Throws:
org.apache.directory.shared.asn1.codec.EncoderException

toString

public java.lang.String toString()
Return the simple authentication as a string

Returns:
The simple authentication string.


Copyright © 2003-2006 . All Rights Reserved.