Package ball.activation
Class FilterDataSource
- java.lang.Object
-
- ball.activation.AbstractDataSource
-
- ball.activation.FilterDataSource
-
- All Implemented Interfaces:
DataSourceDefaultMethods
,DataSource
- Direct Known Subclasses:
ReaderWriterDataSource
public abstract class FilterDataSource extends AbstractDataSource
AbstractDataSource
base class that wraps anotherDataSource
.- Author:
- Allen D. Ball
-
-
Field Summary
-
Fields inherited from interface ball.activation.DataSourceDefaultMethods
APPLICATION_OCTET_STREAM, APPLICATION_XML, CONTENT_TYPE, TEXT_HTML, TEXT_PLAIN
-
-
Constructor Summary
Constructors Modifier Constructor Description protected
FilterDataSource(DataSource ds)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description String
getContentType()
protected DataSource
getDataSource()
Method to get the filteredDataSource
.InputStream
getInputStream()
String
getName()
OutputStream
getOutputStream()
void
setContentType(String type)
void
setName(String name)
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface ball.activation.DataSourceDefaultMethods
clear, getInputStream, getOutputStream, length, wrap, wrap
-
-
-
-
Constructor Detail
-
FilterDataSource
@ConstructorProperties("dataSource") protected FilterDataSource(DataSource ds)
- Parameters:
ds
- The filteredDataSource
.
-
-
Method Detail
-
getDataSource
protected DataSource getDataSource()
Method to get the filteredDataSource
.- Returns:
- The filtered
DataSource
.
-
getName
public String getName()
- Specified by:
getName
in interfaceDataSource
- Overrides:
getName
in classAbstractDataSource
-
setName
public void setName(String name)
- Specified by:
setName
in interfaceDataSourceDefaultMethods
- Overrides:
setName
in classAbstractDataSource
-
getContentType
public String getContentType()
- Specified by:
getContentType
in interfaceDataSource
- Overrides:
getContentType
in classAbstractDataSource
-
setContentType
public void setContentType(String type)
- Specified by:
setContentType
in interfaceDataSourceDefaultMethods
- Overrides:
setContentType
in classAbstractDataSource
-
getInputStream
public InputStream getInputStream() throws IOException
- Throws:
IOException
-
getOutputStream
public OutputStream getOutputStream() throws IOException
- Throws:
IOException
-
-