FileDocCategorySizeDatePackage
SMTPSession.javaAPI DocApache James 2.3.15801Fri Jan 12 12:56:26 GMT 2007org.apache.james.smtpserver

SMTPSession

public interface SMTPSession
All the handlers access this interface to communicate with SMTPHandler object

Fields Summary
public static final String
MESG_FAILED
public static final String
SENDER
public static final String
RCPT_LIST
public static final String
CURRENT_HELO_MODE
Constructors Summary
Methods Summary
public voidabortMessage()
this makes the message to be dropped inprotocol

public java.lang.StringclearResponseBuffer()
Clears the response buffer, returning the String of characters in the buffer.

return
the data in the response buffer

public voidendSession()
this makes the session to close

public java.lang.StringgetCommandArgument()
Returns currently process command argument

return
current command argument

public java.lang.StringgetCommandName()
Returns currently process command name

return
current command name

public SMTPHandlerConfigurationDatagetConfigurationData()
Returns SMTPHandler service wide configuration

return
SMTPHandlerConfigurationData

public java.io.InputStreamgetInputStream()
Returns Inputstream for handling messages and commands

return
InputStream object

public org.apache.mailet.MailgetMail()
Returns Mail object for message handlers to process

return
Mail object

public java.lang.StringgetRemoteHost()
Returns host name of the client

return
hostname of the client

public java.lang.StringgetRemoteIPAddress()
Returns host ip address of the client

return
host ip address of the client

public java.lang.StringBuffergetResponseBuffer()
Returns ResponseBuffer, this optimizes the unecessary creation of resources by each handler object

return
responseBuffer

public java.lang.StringgetSessionID()
Returns the SMTP session id

return
SMTP session id

public java.util.HashMapgetState()
Returns Map that consists of the state of the SMTPSession

return
map of the current SMTPSession state

public java.lang.StringgetUser()
Returns the user name associated with this SMTP interaction.

return
the user name

public org.apache.james.util.watchdog.WatchdoggetWatchdog()
Returns Watchdog object used for handling timeout

return
Watchdog object

public booleanisAuthRequired()
Returns whether Authentication is required or not

return
authentication required or not

public booleanisBlockListed()
Returns the blocklisted status

return
blocklisted

public booleanisRelayingAllowed()
Returns whether Relaying is allowed or not

return
the relaying status

public booleanisSessionEnded()
Returns the session status

return
if the session is open or closed

public java.lang.StringreadCommandLine()
Reads a line of characters off the command line.

return
the trimmed input line
throws
IOException if an exception is generated reading in the input characters

public voidresetState()
Resets message-specific, but not authenticated user, state.

public voidsetBlockListed(boolean blocklisted)
Sets the blocklisted value

param
blocklisted

public voidsetMail(org.apache.mailet.Mail mail)
Sets the MailImpl object for further processing

param
mail MailImpl object

public voidsetUser(java.lang.String user)
Sets the user name associated with this SMTP interaction.

param
userID the user name

public booleanuseHeloEhloEnforcement()
Returns whether remote server needs to send HELO/EHLO

return
HELO/EHLO required or not

public voidwriteResponse(java.lang.String respString)
Writes response string to the client

param
respString String that needs to send to the client