public class OFSNFileHandler extends Object implements LargeProductQueryHandler, XMLQueryMetKeys, OFSNXMLMetKeys, OFSNMetKeys, OFSNXMLConfigMetKeys
OFSN, RETURN_TYPE
DIR_ENTRY_TAG, DIR_LISTING_NS, DIR_RESULT_TAG, FILE_SIZE_TAG, OFSN_TAG, XML_MIME_TYPE
GET_CMD, LISTING_CMD, OFSN_COMPUTE_DIR_SIZE, OFSN_COMPUTE_FILE_SIZE, OFSN_XML_CONF_FILE_KEY
HANDLER_CLASSNAME_ATTR, HANDLER_NAME_ATTR, HANDLER_TAG, HANDLER_TYPE_ATTR, OFSN_CFG_ID_ATTR, OFSN_CFG_NAME_ATTR, OFSN_PRODUCT_ROOT_ATTR, PROPERTY_MIMETYPE_ATTR, PROPERTY_NAME_ATTR, PROPERTY_TAG, PROPERTY_VALUE_ATTR
Constructor and Description |
---|
OFSNFileHandler() |
Modifier and Type | Method and Description |
---|---|
void |
close(String id)
Close off a product.
|
OFSNFileHandlerConfiguration |
getOfsnFileHandlerConfiguration() |
XMLQuery |
query(XMLQuery xmlQuery)
Run a query.
|
byte[] |
retrieveChunk(String id,
long offset,
int length)
Retrieve a chunk of a product.
|
public OFSNFileHandler() throws InstantiationException
InstantiationException
public XMLQuery query(XMLQuery xmlQuery) throws ProductException
QueryHandler
query
in interface QueryHandler
xmlQuery
- The query.ProductException
- if an error occurs.public void close(String id)
LargeProductQueryHandler
IOException
when closing a file.close
in interface LargeProductQueryHandler
id
- Product ID.public OFSNFileHandlerConfiguration getOfsnFileHandlerConfiguration()
public byte[] retrieveChunk(String id, long offset, int length) throws ProductException
LargeProductQueryHandler
retrieveChunk
in interface LargeProductQueryHandler
id
- Product ID.offset
- Where in the product to get a chunk of it.length
- How much of the product to get.ProductException
- if an error occurs.Copyright © 1999–2017 Apache OODT. All rights reserved.