org.apache.james.mime4j.parser
public class MimeEntity extends AbstractEntity
body, config, endState, log, parent, startState, state
Constructor and Description |
---|
MimeEntity(LineNumberSource lineSource,
BufferedLineReaderInputStream inbuffer,
BodyDescriptor parent,
int startState,
int endState) |
MimeEntity(LineNumberSource lineSource,
BufferedLineReaderInputStream inbuffer,
BodyDescriptor parent,
int startState,
int endState,
MimeEntityConfig config) |
Modifier and Type | Method and Description |
---|---|
EntityStateMachine |
advance()
Advances the state machine to the next state in the
process of the MIME stream parsing.
|
java.io.InputStream |
getContentStream()
Returns content stream of the entity body.
|
protected LineReaderInputStream |
getDataStream() |
protected int |
getLineNumber()
Returns the current line number or
-1 if line number
information is not available. |
int |
getRecursionMode() |
void |
setRecursionMode(int recursionMode)
Sets the current recursion mode.
|
void |
skipHeader(java.lang.String contentType) |
debug, getBodyDescriptor, getField, getState, message, monitor, newBodyDescriptor, parseField, stateToString, toString, warn
public MimeEntity(LineNumberSource lineSource, BufferedLineReaderInputStream inbuffer, BodyDescriptor parent, int startState, int endState, MimeEntityConfig config)
public MimeEntity(LineNumberSource lineSource, BufferedLineReaderInputStream inbuffer, BodyDescriptor parent, int startState, int endState)
public int getRecursionMode()
public void setRecursionMode(int recursionMode)
EntityStateMachine
RecursionMode.M_RAW
mode does not parse the part at all.
RecursionMode.M_RECURSE
mode recursively parses each mail
when an message/rfc822
part is encounted;
RecursionMode.M_NO_RECURSE
does not.RecursionMode
public void skipHeader(java.lang.String contentType)
protected int getLineNumber()
AbstractEntity
-1
if line number
information is not available.getLineNumber
in class AbstractEntity
protected LineReaderInputStream getDataStream()
getDataStream
in class AbstractEntity
public EntityStateMachine advance() throws java.io.IOException, MimeException
EntityStateMachine
null
otherwise.java.io.IOException
- if an I/O error occurs.MimeException
- if the message can not be processed due
to the MIME specification violation.public java.io.InputStream getContentStream()
EntityStateMachine
Copyright © 2004-2014. All Rights Reserved.