|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectinfo.sswap.ontologies.data.impl.AbstractData
info.sswap.ontologies.data.impl.LiteralData
public class LiteralData
Support for reading and writing literal data (the value of the data:literalData predicate).
Field Summary |
---|
Fields inherited from class info.sswap.ontologies.data.impl.AbstractData |
---|
DataFormatType, sswapDocument, sswapIndividual |
Constructor Summary | |
---|---|
LiteralData(SSWAPIndividual sswapIndividual)
Construct a literal data object for reading/writing. |
Method Summary | |
---|---|
java.io.InputStream |
readData()
Read the data, reading nothing (but no error) if there is no data to read. |
void |
writeData(java.io.InputStream inputStream)
Write to the property data:literalData, creating one if needed |
Methods inherited from class info.sswap.ontologies.data.impl.AbstractData |
---|
getAccessors, getFormats, getIndividual, getParsers, getSerializers, getValidators, hasValue, inputStreamToString, parse, serialize, setValue, stringToInputStream, validate |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public LiteralData(SSWAPIndividual sswapIndividual) throws DataException
sswapIndividual
- the data source or sink
DataException
- on any error establishing literal data supportMethod Detail |
---|
public java.io.InputStream readData() throws java.io.IOException, DataException
The data source must be of type data:DataFormat
for any
meaningful read; otherwise a read "succeeds" with trivial empty content.
java.io.IOException
- on any stream error
DataException
- on data error such as parsing, validating, etc.public void writeData(java.io.InputStream inputStream) throws java.io.IOException, DataException
inputStream
- stream from which to read the data to write
java.io.IOException
- on any stream error
DataException
- on data error such as validating, serializing, etc.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |