public interface Multipart extends Body
| Modifier and Type | Method and Description |
|---|---|
void |
addBodyPart(Entity bodyPart)
Adds a body part to the end of the list of body parts.
|
void |
addBodyPart(Entity bodyPart,
int index)
Inserts a body part at the specified position in the list of body parts.
|
List<Entity> |
getBodyParts()
Gets the list of body parts.
|
int |
getCount()
Returns the number of body parts.
|
String |
getEpilogue()
Gets the epilogue or null if the message has no epilogue
|
String |
getPreamble()
Gets the preamble or null if the message has no preamble.
|
String |
getSubType()
Gets the multipart sub-type.
|
Entity |
removeBodyPart(int index)
Removes the body part at the specified position in the list of body
parts.
|
Entity |
replaceBodyPart(Entity bodyPart,
int index)
Replaces the body part at the specified position in the list of body
parts with the specified body part.
|
void |
setBodyParts(List<Entity> bodyParts)
Sets the list of body parts.
|
void |
setEpilogue(String epilogue)
Sets the epilogue value, or remove it if the value passed is null.
|
void |
setPreamble(String preamble)
Sets the preamble with a value or null to remove the preamble.
|
disposeString getSubType()
alternative (the
default) or parallel. See RFC 2045 for common sub-types
and their meaning.int getCount()
Entity objects.List<Entity> getBodyParts()
Entity objects.void setBodyParts(List<Entity> bodyParts)
bodyParts - the new list of Entity objects.void addBodyPart(Entity bodyPart)
bodyPart - the body part.void addBodyPart(Entity bodyPart, int index)
bodyPart - the body part.index - index at which the specified body part is to be inserted.IndexOutOfBoundsException - if the index is out of range (index < 0 || index >
getCount()).Entity removeBodyPart(int index)
index - index of the body part to be removed.IndexOutOfBoundsException - if the index is out of range (index < 0 || index >=
getCount()).Entity replaceBodyPart(Entity bodyPart, int index)
bodyPart - body part to be stored at the specified position.index - index of body part to replace.IndexOutOfBoundsException - if the index is out of range (index < 0 || index >=
getCount()).String getPreamble()
void setPreamble(String preamble)
preamble - the preamble.String getEpilogue()
void setEpilogue(String epilogue)
epilogue - the epilogue.Copyright © 2004-2012 The Apache Software Foundation. All Rights Reserved.