com.xpn.xwiki.test.smtp
Class SmtpState

java.lang.Object
  extended bycom.xpn.xwiki.test.smtp.SmtpState

public class SmtpState
extends java.lang.Object

SMTP server state.


Field Summary
static SmtpState CONNECT
          CONNECT state: waiting for a client connection.
private static byte CONNECT_BYTE
          Internal representation of the CONNECT state.
static SmtpState DATA_BODY
          Processing body text.
private static byte DATA_BODY_BYTE
          Internal representation of the DATA_BODY state.
static SmtpState DATA_HDR
          Waiting for headers.
private static byte DATA_HEADER_BYTE
          Internal representation of the DATA_HEADER state.
static SmtpState GREET
          GREET state: wating for a ELHO message.
private static byte GREET_BYTE
          Internal representation of the GREET state.
static SmtpState MAIL
          MAIL state: waiting for the MAIL FROM: command.
private static byte MAIL_BYTE
          Internal representation of the MAIL state.
static SmtpState QUIT
          End of client transmission.
private static byte QUIT_BYTE
          Internal representation of the QUIT state.
static SmtpState RCPT
          RCPT state: waiting for a RCPT <email address> command.
private static byte RCPT_BYTE
          Internal representation of the RCPT state.
private  byte value
          Internal representation of the state.
 
Constructor Summary
private SmtpState(byte value)
          Create a new SmtpState object.
 
Method Summary
 java.lang.String toString()
          String representation of this SmtpState.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

value

private byte value
Internal representation of the state.


CONNECT_BYTE

private static final byte CONNECT_BYTE
Internal representation of the CONNECT state.

See Also:
Constant Field Values

GREET_BYTE

private static final byte GREET_BYTE
Internal representation of the GREET state.

See Also:
Constant Field Values

MAIL_BYTE

private static final byte MAIL_BYTE
Internal representation of the MAIL state.

See Also:
Constant Field Values

RCPT_BYTE

private static final byte RCPT_BYTE
Internal representation of the RCPT state.

See Also:
Constant Field Values

DATA_HEADER_BYTE

private static final byte DATA_HEADER_BYTE
Internal representation of the DATA_HEADER state.

See Also:
Constant Field Values

DATA_BODY_BYTE

private static final byte DATA_BODY_BYTE
Internal representation of the DATA_BODY state.

See Also:
Constant Field Values

QUIT_BYTE

private static final byte QUIT_BYTE
Internal representation of the QUIT state.

See Also:
Constant Field Values

CONNECT

public static final SmtpState CONNECT
CONNECT state: waiting for a client connection.


GREET

public static final SmtpState GREET
GREET state: wating for a ELHO message.


MAIL

public static final SmtpState MAIL
MAIL state: waiting for the MAIL FROM: command.


RCPT

public static final SmtpState RCPT
RCPT state: waiting for a RCPT <email address> command.


DATA_HDR

public static final SmtpState DATA_HDR
Waiting for headers.


DATA_BODY

public static final SmtpState DATA_BODY
Processing body text.


QUIT

public static final SmtpState QUIT
End of client transmission.

Constructor Detail

SmtpState

private SmtpState(byte value)
Create a new SmtpState object. Private to ensure that only valid states can be created.

Parameters:
value - one of the _BYTE values.
Method Detail

toString

public java.lang.String toString()
String representation of this SmtpState.

Returns:
a String


Copyright 2003 Ludovic Dubost