com.ibm.portal.resolver.data
Interface JsonDataSink
- All Superinterfaces:
- DataSink, Disposable
public interface JsonDataSink
- extends DataSink
Identifies a data sink that is able to handle json feeds. The resolver
infrastructure takes care of interpreting the incoming request body as a json
data stream and provides it in form of a JsonParserReader
object to
the data sink.
- Since:
- 7.0.0.1
- Note:
This interface is designed to be implemented by clients. |
read
DataSource read(JsonParserReader in,
java.lang.String mimeType)
throws java.io.IOException
- Handles the data input and optionally returns a
DataSource
that
represents the response
- Parameters:
in
- the input stream to the data , not null
mimeType
- the mime type of the content in the stream, not
null
- Returns:
- the data source that represents the response. May be
null
to indicate that the response does not provide
content.
- Throws:
java.io.IOException
- if the data cannot be processed