gov.nih.nci.caarray.services.external.v1_0.data
Interface DataService


public interface DataService

Remote service for retrieving file and parsed data. Used by the grid service, and can also be used directly by EJB clients.

Author:
dkokotov

Field Summary
static java.lang.String JNDI_NAME
          The JNDI name to look up this Remote EJB under.
 
Method Summary
 MageTabFileSet exportMageTab(CaArrayEntityReference experimentRef)
          Retrieves a set of files containing the MAGE-TAB IDF and SDRF for the experiment identified by the given reference.
 DataSet getDataSet(DataSetRequest dataSetRequest)
          Retrieves the parsed data set identified by the given request.
 FileStreamableContents streamFileContents(CaArrayEntityReference fileRef, boolean compressed)
          Returns a RemoteInputStream through which the client can retrieve the data for the file identified by the given reference.
 

Field Detail

JNDI_NAME

static final java.lang.String JNDI_NAME
The JNDI name to look up this Remote EJB under.

See Also:
Constant Field Values
Method Detail

getDataSet

DataSet getDataSet(DataSetRequest dataSetRequest)
                   throws InvalidReferenceException,
                          InvalidInputException,
                          InconsistentDataSetsException
Retrieves the parsed data set identified by the given request. The DataSet will contain a HybridizationData for each Hybridization referenced by the request, and/or for each Hybridization linked to a data File referenced by the request. Each HybridizationData will contain one DataColumn for each QuantitationType referenced by the request.

Parameters:
dataSetRequest - a DataSetRequest instance identifying the parsed data to be retrieved. The request must specify at least one hybridization or one file, and at least one quantitation type.
Returns:
the DataSet with the requested parsed data, as specified above.
Throws:
InvalidReferenceException - if any of the hybridization, file or quantitation references in the dataSetRequest are not valid
InvalidInputException - if no quantitation type is specified in the request, or if at least one file OR one hybridization is not specified in the request.
InconsistentDataSetsException - if the data sets for the hybridizations and/or files in the request are not consistent, e.g. do not correspond to the same design element list.

streamFileContents

FileStreamableContents streamFileContents(CaArrayEntityReference fileRef,
                                          boolean compressed)
                                          throws InvalidReferenceException,
                                                 DataTransferException
Returns a RemoteInputStream through which the client can retrieve the data for the file identified by the given reference. The client must take care to ensure the RemoteInputStream is closed when the contents is read, even when exceptions occur.

Parameters:
fileRef - the reference identifying the file to retrieve.
compressed - if true, then the RemoteInputStream will return the contents of the file compressed using Gzip
Returns:
the remote input stream (using the rmiio library) from which the file contents can be read.
Throws:
InvalidReferenceException - if the fileRef is not a valid file reference.
DataTransferException - if there is an error streaming the data.

exportMageTab

MageTabFileSet exportMageTab(CaArrayEntityReference experimentRef)
                             throws InvalidReferenceException,
                                    DataTransferException
Retrieves a set of files containing the MAGE-TAB IDF and SDRF for the experiment identified by the given reference. The IDF and SDRF are generated dynamically. The file set also contains references to the data files referenced by the SDRF.

Parameters:
experimentRef - reference identifying the experiment
Returns:
a MageTabFileSet consisting of the generated IDF and SDRF for this experiment, and references to the data files linked to hybridizations in the experiment
Throws:
InvalidReferenceException - if the experimentRef is not a valid experiment reference
DataTransferException - if there is an error generating the mage-tab file data