Class TestDataSource
- java.lang.Object
-
- org.apache.axiom.testutils.activation.TestDataSource
-
- All Implemented Interfaces:
DataSource
public class TestDataSource extends Object implements DataSource
Test data source that produces a byte sequence with specified length and with all bytes equal to a specified value.
-
-
Constructor Summary
Constructors Constructor Description TestDataSource(int value, long length)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description StringgetContentType()InputStreamgetInputStream()StringgetName()OutputStreamgetOutputStream()
-
-
-
Method Detail
-
getName
public String getName()
- Specified by:
getNamein interfaceDataSource
-
getContentType
public String getContentType()
- Specified by:
getContentTypein interfaceDataSource
-
getInputStream
public InputStream getInputStream() throws IOException
- Specified by:
getInputStreamin interfaceDataSource- Throws:
IOException
-
getOutputStream
public OutputStream getOutputStream() throws IOException
- Specified by:
getOutputStreamin interfaceDataSource- Throws:
IOException
-
-