|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectorg.apache.ldap.clients.LdapBind
public class LdapBind
Ldap client for the ADD operation
| Constructor Summary | |
|---|---|
LdapBind(java.lang.String[] argv)
Take the command line string and pass it into the argument parser, which will set our option flags. |
|
| Method Summary | |
|---|---|
BindResponse |
bind(int id)
Send the bind request to the LDAP server. |
void |
connect()
Connect to the LDAP server through a socket and establish the Input and Output Streams. |
void |
disconnect()
Close the socket |
void |
enableLogging(Level level)
Set the logging priority of the logger object |
MessageDecoder |
getDecoder()
Get the message decoder used to tranform the ASN1 from the server |
MessageEncoder |
getEncoder()
Get the message encoder used to transform the message into ASN1 nototation being sent to the server |
java.io.InputStream |
getIn()
Get the input stream used to send messages to the server |
Logger |
getLog()
Get the instance of the logger |
java.lang.String |
getModule()
Get the module's name |
BindOpts |
getOpts()
Get the command line options from the clinet |
java.io.OutputStream |
getOut()
Get the output stream used to receive messages from the server |
java.net.Socket |
getSocket()
Get the socket used to connect to the server machine |
static void |
main(java.lang.String[] args)
Main method for the Bind client. |
void |
setDecoder(MessageDecoder decoder)
Set the Message decoder used to tranform the ASN1 from the server |
void |
setEncoder(MessageEncoder encoder)
Set the Message encoder used to transform the message into ASN1 nototation being sent to the server |
void |
setIn(java.io.InputStream stream)
Set the input stream used to send messages to the server |
void |
setLog(Logger logger)
Set the instance of the logger |
void |
setModule(java.lang.String module)
Set the module's name |
void |
setOpts(BindOpts opts)
Set the command line options from the clinet |
void |
setOut(java.io.OutputStream stream)
Set the output stream used to receive messages from the server |
void |
setSocket(java.net.Socket socket)
Set the socket used to connect to the server machine |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public LdapBind(java.lang.String[] argv)
argv - The command line string| Method Detail |
|---|
public java.lang.String getModule()
public void enableLogging(Level level)
level - The level to set the logging topublic MessageDecoder getDecoder()
public MessageEncoder getEncoder()
public java.io.InputStream getIn()
public Logger getLog()
public BindOpts getOpts()
public java.io.OutputStream getOut()
public java.net.Socket getSocket()
public void setModule(java.lang.String module)
module - The module name to set.public void setDecoder(MessageDecoder decoder)
decoder - Message decoder used to tranform the ASN1 from
serverpublic void setEncoder(MessageEncoder encoder)
encoder - Message encoder used to transform the message into ASN1
nototation being sent to the serverpublic void setIn(java.io.InputStream stream)
stream - Set the input stream used to send messages to the serverpublic void setLog(Logger logger)
logger - logger objectpublic void setOpts(BindOpts opts)
opts - Command line options from the clinetpublic void setOut(java.io.OutputStream stream)
stream - Output stream used to receive messages from the serverpublic void setSocket(java.net.Socket socket)
a_socket - Socket used to connect to the server machine
public void connect()
throws java.net.UnknownHostException,
java.io.IOException
java.net.UnknownHostException - The hostname or the Address of
server could not be found
java.io.IOException - There was a error opening or establishing the socket
public BindResponse bind(int id)
throws java.net.UnknownHostException,
java.io.IOException
id - Message number of this request, If this is a simple
bind, the ID will be one.
java.net.UnknownHostException - The hostname or the Address of
server could not be found
java.io.IOException - There was a error opening or establishing the socket
public void disconnect()
throws java.io.IOException
java.io.IOException - Could not close the socketpublic static void main(java.lang.String[] args)
args - Command line string
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||