Apache CXF API

org.apache.cxf.jaxrs.ext.multipart
Class AttachmentBuilder

java.lang.Object
  extended by org.apache.cxf.jaxrs.ext.multipart.AttachmentBuilder

public class AttachmentBuilder
extends Object

Fluid builder class for Attachment objects.


Constructor Summary
AttachmentBuilder()
           
 
Method Summary
 Attachment build()
           
 AttachmentBuilder contentDisposition(ContentDisposition newContentDisposition)
           
 AttachmentBuilder dataHandler(DataHandler newDataHandler)
           
 AttachmentBuilder header(String key, String value)
           
 AttachmentBuilder headers(javax.ws.rs.core.MultivaluedMap<String,String> allHeaders)
          Set all of the headers.
 AttachmentBuilder id(String id)
           
 AttachmentBuilder mediaType(String mediaType)
           
 AttachmentBuilder object(Object theObject)
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

AttachmentBuilder

public AttachmentBuilder()
Method Detail

id

public AttachmentBuilder id(String id)

mediaType

public AttachmentBuilder mediaType(String mediaType)

object

public AttachmentBuilder object(Object theObject)

dataHandler

public AttachmentBuilder dataHandler(DataHandler newDataHandler)

header

public AttachmentBuilder header(String key,
                                String value)

headers

public AttachmentBuilder headers(javax.ws.rs.core.MultivaluedMap<String,String> allHeaders)
Set all of the headers. This will overwrite any content ID, media type, ContentDisposition, or other header set by previous calls.

Parameters:
allHeaders -
Returns:

contentDisposition

public AttachmentBuilder contentDisposition(ContentDisposition newContentDisposition)

build

public Attachment build()

Apache CXF API

Apache CXF