javax.mail
Interface MultipartDataSource

All Known Implementing Classes:
IMAPMultipartDataSource

public interface MultipartDataSource

A data source that contains body parts.

See Also:
DataSource

Method Summary
 BodyPart getBodyPart(int index)
          Returns the specified body part.
 int getCount()
          Returns the number of body parts.
 

Method Detail

getCount

int getCount()
Returns the number of body parts.


getBodyPart

BodyPart getBodyPart(int index)
                     throws MessagingException
Returns the specified body part. Body parts are numbered starting at 0.

Parameters:
index - the index of the desired body part
Throws:
java.lang.IndexOutOfBoundsException - if the given index is out of range
MessagingException