org.glassfish.jersey.message.internal
Class DataSourceProvider.ByteArrayDataSource
java.lang.Object
org.glassfish.jersey.message.internal.DataSourceProvider.ByteArrayDataSource
- All Implemented Interfaces:
- DataSource
- Enclosing class:
- DataSourceProvider
public static class DataSourceProvider.ByteArrayDataSource
- extends Object
- implements DataSource
Modified from javax.mail.util.ByteArrayDataSource
A DataSource backed by a byte array. The byte array may be
passed in directly, or may be initialized from an InputStream
or a String.
- Since:
- JavaMail 1.4
- Author:
- John Mani, Bill Shannon, Max Spivak
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
DataSourceProvider.ByteArrayDataSource
public DataSourceProvider.ByteArrayDataSource(InputStream is,
String type)
throws IOException
- Throws:
IOException
getInputStream
public InputStream getInputStream()
throws IOException
- Specified by:
getInputStream in interface DataSource
- Throws:
IOException
getOutputStream
public OutputStream getOutputStream()
throws IOException
- Specified by:
getOutputStream in interface DataSource
- Throws:
IOException
getContentType
public String getContentType()
- Specified by:
getContentType in interface DataSource
getName
public String getName()
- Specified by:
getName in interface DataSource
setName
public void setName(String name)
Copyright © 2007-2014, Oracle and/or its affiliates. All Rights Reserved. Use is subject to license terms.