org.apache.james.protocols.smtp
Class SMTPResponse

java.lang.Object
  extended by org.apache.james.protocols.api.AbstractResponse
      extended by org.apache.james.protocols.smtp.SMTPResponse
All Implemented Interfaces:
Response
Direct Known Subclasses:
SMTPStartTLSResponse

public class SMTPResponse
extends AbstractResponse

Contains an SMTP result


Field Summary
 
Fields inherited from class org.apache.james.protocols.api.AbstractResponse
lines
 
Fields inherited from interface org.apache.james.protocols.api.Response
DISCONNECT
 
Constructor Summary
protected SMTPResponse()
           
  SMTPResponse(String rawLine)
          Construct a new SMTPResponse.
  SMTPResponse(String code, CharSequence description)
          Construct a new SMTPResponse.
 
Method Summary
 List<CharSequence> getLines()
           
 
Methods inherited from class org.apache.james.protocols.api.AbstractResponse
appendLine, getRetCode, isEndSession, setEndSession, setRetCode, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

SMTPResponse

protected SMTPResponse()

SMTPResponse

public SMTPResponse(String code,
                    CharSequence description)
Construct a new SMTPResponse. The given code and description can not be null, if null an IllegalArgumentException get thrown

Parameters:
code - the returnCode
description - the description

SMTPResponse

public SMTPResponse(String rawLine)
Construct a new SMTPResponse. The given rawLine need to be in format [SMTPResponseReturnCode SMTResponseDescription]. If this is not the case an IllegalArgumentException get thrown.

Parameters:
rawLine - the raw SMTPResponse
Method Detail

getLines

public List<CharSequence> getLines()
See Also:
Response.getLines()


Copyright © 2010-2011 The Apache Software Foundation. All Rights Reserved.