com.sun.xml.ws.util
Class ByteArrayDataSource

java.lang.Object
  extended by com.sun.xml.ws.util.ByteArrayDataSource
All Implemented Interfaces:
DataSource

public final class ByteArrayDataSource
extends Object
implements DataSource

DataSource backed by a byte buffer.

Author:
Kohsuke Kawaguchi

Constructor Summary
ByteArrayDataSource(byte[] buf, int start, int length, String contentType)
           
ByteArrayDataSource(byte[] buf, int length, String contentType)
           
ByteArrayDataSource(byte[] buf, String contentType)
           
 
Method Summary
 String getContentType()
           
 InputStream getInputStream()
           
 String getName()
           
 OutputStream getOutputStream()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ByteArrayDataSource

public ByteArrayDataSource(byte[] buf,
                           String contentType)

ByteArrayDataSource

public ByteArrayDataSource(byte[] buf,
                           int length,
                           String contentType)

ByteArrayDataSource

public ByteArrayDataSource(byte[] buf,
                           int start,
                           int length,
                           String contentType)
Method Detail

getContentType

public String getContentType()
Specified by:
getContentType in interface DataSource

getInputStream

public InputStream getInputStream()
Specified by:
getInputStream in interface DataSource

getName

public String getName()
Specified by:
getName in interface DataSource

getOutputStream

public OutputStream getOutputStream()
Specified by:
getOutputStream in interface DataSource


Copyright © 2005-2015 Oracle Corporation. All Rights Reserved.