be.ehealth.technicalconnector.utils
Class ByteArrayDatasource
java.lang.Object
be.ehealth.technicalconnector.utils.ByteArrayDatasource
- All Implemented Interfaces:
- DataSource
- Direct Known Subclasses:
- ByteArrayDatasource
public class ByteArrayDatasource
- extends Object
- implements DataSource
Datasource for the DataHandler. Implementation of DataSource
ByteArrayDatasource
public ByteArrayDatasource(byte[] byteArray)
- Creates a new ByteArrayDataSource from a byte array
- Parameters:
byteArray
-
ByteArrayDatasource
public ByteArrayDatasource(byte[] byteArray,
String contentType)
- Creates a new ByteArrayDataSource from a byte array
- Parameters:
byteArray
-
getInputStream
public InputStream getInputStream()
throws IOException
- Specified by:
getInputStream
in interface DataSource
- Throws:
IOException
- See Also:
DataSource.getInputStream()
getOutputStream
public OutputStream getOutputStream()
throws IOException
- Specified by:
getOutputStream
in interface DataSource
- Throws:
IOException
- See Also:
DataSource.getOutputStream()
getContentType
public String getContentType()
- Specified by:
getContentType
in interface DataSource
- See Also:
DataSource.getContentType()
getName
public String getName()
- Specified by:
getName
in interface DataSource
- See Also:
DataSource.getName()
getByteArray
public byte[] getByteArray()
- Returns:
- the byteArray
Connector Business ORGPHARMACY 3.13.1 API
Copyright © {inceptionYear}-2017 eHealth. All Rights Reserved.