FileDocCategorySizeDatePackage
MultipartDataSource.javaAPI DocGlassfish v2 API3374Mon May 14 15:28:48 BST 2007javax.mail

MultipartDataSource

public interface MultipartDataSource implements DataSource
MultipartDataSource is a DataSource that contains body parts. This allows "mail aware" DataContentHandlers to be implemented more efficiently by being aware of such DataSources and using the appropriate methods to access BodyParts.

Note that the data of a MultipartDataSource is also available as an input stream.

This interface will typically be implemented by providers that preparse multipart bodies, for example an IMAP provider.

version
1.8, 07/05/04
author
John Mani
see
javax.activation.DataSource

Fields Summary
Constructors Summary
Methods Summary
public javax.mail.BodyPartgetBodyPart(int index)
Get the specified Part. Parts are numbered starting at 0.

param
index the index of the desired Part
return
the Part
exception
IndexOutOfBoundsException if the given index is out of range.
exception
MessagingException

public intgetCount()
Return the number of enclosed BodyPart objects.

return
number of parts