org.gcube.common.searchservice.searchlibrary.resultset.elements
Class ResultElementBLOBBase

java.lang.Object
  extended by org.gcube.common.searchservice.searchlibrary.resultset.elements.ResultElementBase
      extended by org.gcube.common.searchservice.searchlibrary.resultset.elements.ResultElementBLOBBase
Direct Known Subclasses:
ResultElementBLOBGeneric

public abstract class ResultElementBLOBBase
extends ResultElementBase

This class is the base class that must be extended by anyone wishing to implement a custom Record element class for BLOB records. Every class extending this one must define an accessible default constructor with an empty argument list

Author:
UoA

Constructor Summary
ResultElementBLOBBase()
           
 
Method Summary
abstract  void close()
          closes underlying structures, streams
abstract  java.io.InputStream getContentOfBLOB()
          Retrieves the blob content
abstract  void setContentOfBLOB(java.io.InputStream content)
          sets the blob content
 
Methods inherited from class org.gcube.common.searchservice.searchlibrary.resultset.elements.ResultElementBase
fromXML, getRecordAttributes, getRecordAttributes, isValid, RS_fromXML, RS_toXML, setRecordAttributes, toXML
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ResultElementBLOBBase

public ResultElementBLOBBase()
Method Detail

getContentOfBLOB

public abstract java.io.InputStream getContentOfBLOB()
                                              throws java.lang.Exception
Retrieves the blob content

Returns:
the content
Throws:
java.lang.Exception - An unrecoverbale for the operation error occured

setContentOfBLOB

public abstract void setContentOfBLOB(java.io.InputStream content)
                               throws java.lang.Exception
sets the blob content

Parameters:
content - the content
Throws:
java.lang.Exception - An unrecoverbale for the operation error occured

close

public abstract void close()
                    throws java.lang.Exception
closes underlying structures, streams

Throws:
java.lang.Exception - An unrecoverable for the operation error occured