cxf-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From serg...@apache.org
Subject svn commit: r1221779 - in /cxf/branches/2.4.x-fixes: ./ rt/frontend/jaxrs/src/main/java/org/apache/cxf/jaxrs/ext/multipart/Attachment.java rt/frontend/jaxrs/src/main/java/org/apache/cxf/jaxrs/ext/multipart/AttachmentBuilder.java
Date Wed, 21 Dec 2011 15:58:55 GMT
Author: sergeyb
Date: Wed Dec 21 15:58:54 2011
New Revision: 1221779

URL: http://svn.apache.org/viewvc?rev=1221779&view=rev
Log:
Merged revisions 1221777 via svnmerge from 
https://svn.apache.org/repos/asf/cxf/trunk

........
  r1221777 | bimargulies | 2011-12-21 15:54:26 +0000 (Wed, 21 Dec 2011) | 1 line
  
  CXF-3988: First attempt at a builder/fluid pattern for making attachments.
........

Added:
    cxf/branches/2.4.x-fixes/rt/frontend/jaxrs/src/main/java/org/apache/cxf/jaxrs/ext/multipart/AttachmentBuilder.java
      - copied unchanged from r1221777, cxf/trunk/rt/frontend/jaxrs/src/main/java/org/apache/cxf/jaxrs/ext/multipart/AttachmentBuilder.java
Modified:
    cxf/branches/2.4.x-fixes/   (props changed)
    cxf/branches/2.4.x-fixes/rt/frontend/jaxrs/src/main/java/org/apache/cxf/jaxrs/ext/multipart/Attachment.java

Propchange: cxf/branches/2.4.x-fixes/
------------------------------------------------------------------------------
--- svn:mergeinfo (original)
+++ svn:mergeinfo Wed Dec 21 15:58:54 2011
@@ -1 +1 @@
-/cxf/trunk:1221204,1221208,1221221,1221226,1221511,1221519,1221709,1221776
+/cxf/trunk:1221204,1221208,1221221,1221226,1221511,1221519,1221709,1221776-1221777

Propchange: cxf/branches/2.4.x-fixes/
------------------------------------------------------------------------------
Binary property 'svnmerge-integrated' - no diff available.

Modified: cxf/branches/2.4.x-fixes/rt/frontend/jaxrs/src/main/java/org/apache/cxf/jaxrs/ext/multipart/Attachment.java
URL: http://svn.apache.org/viewvc/cxf/branches/2.4.x-fixes/rt/frontend/jaxrs/src/main/java/org/apache/cxf/jaxrs/ext/multipart/Attachment.java?rev=1221779&r1=1221778&r2=1221779&view=diff
==============================================================================
--- cxf/branches/2.4.x-fixes/rt/frontend/jaxrs/src/main/java/org/apache/cxf/jaxrs/ext/multipart/Attachment.java
(original)
+++ cxf/branches/2.4.x-fixes/rt/frontend/jaxrs/src/main/java/org/apache/cxf/jaxrs/ext/multipart/Attachment.java
Wed Dec 21 15:58:54 2011
@@ -33,6 +33,14 @@ import javax.ws.rs.ext.Providers;
 
 import org.apache.cxf.jaxrs.impl.MetadataMap;
 
+/**
+ * This class represents an attachment; generally a multipart part. 
+ * Some constructors in here are intended only for
+ * internal use in CXF, others are suitable or preparing 
+ * attachments to pass to the {@link org.apache.cxf.jaxrs.client.WebClient} API. 
+ * See the {@link AttachmentBuilder} for a convenient 
+ * way to create attachments for use with {@link org.apache.cxf.jaxrs.client.WebClient}.
+ */
 public class Attachment {
 
     private DataHandler handler;
@@ -86,6 +94,12 @@ public class Attachment {
         headers.putSingle("Content-Type", "application/octet-stream");
     }
     
+    Attachment(MultivaluedMap<String, String> headers, DataHandler handler, Object
object) {
+        this.headers = headers;
+        this.handler = handler;
+        this.object = object;
+    }
+    
     public ContentDisposition getContentDisposition() {
         String header = getHeader("Content-Disposition");
         



Mime
View raw message