Package org.intermine.bio.webservice
Class BioQueryService
- java.lang.Object
-
- org.intermine.webservice.server.WebService
-
- org.intermine.webservice.server.query.AbstractQueryService
-
- org.intermine.bio.webservice.BioQueryService
-
- Direct Known Subclasses:
BEDQueryService,FastaQueryService,GFFQueryService
public abstract class BioQueryService extends org.intermine.webservice.server.query.AbstractQueryServiceA service for exporting query results as gff3.
-
-
Constructor Summary
Constructors Constructor Description BioQueryService(org.intermine.api.InterMineAPI im)Constructor.
-
Method Summary
All Methods Static Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description protected voidcheckPathQuery(org.intermine.pathquery.PathQuery pq)No-op stub.protected voidexecute()protected abstract java.lang.StringgetContentType()protected java.lang.StringgetDefaultFileName()org.intermine.webservice.server.FormatgetDefaultFormat()protected org.intermine.webservice.server.output.OutputgetDefaultOutput(java.io.PrintWriter out, java.io.OutputStream outputstream, java.lang.String sep)protected abstract org.intermine.web.logic.export.ExportergetExporter(org.intermine.pathquery.PathQuery pq)java.io.OutputStreamgetOutputStream()protected static java.util.List<java.lang.String>getPathQueryViews(java.lang.String[] views)Parse path query views from request parameter "view" comma-separatedjava.io.PrintWritergetPrintWriter()protected org.intermine.pathquery.PathQuerygetQuery()Return the query specified in the request, shorn of all duplicate classes in the view.protected java.util.List<org.intermine.pathquery.Path>getQueryPaths(org.intermine.pathquery.PathQuery pq)Parse view strings to Path objectsprotected abstract java.lang.StringgetSuffix()-
Methods inherited from class org.intermine.webservice.server.query.AbstractQueryService
formatIsJsonObj, getQueryBuilder, getSchemaLocation, getSchemaUrl
-
Methods inherited from class org.intermine.webservice.server.WebService
canServe, cleanUp, formatIsFlatFile, formatIsJSON, formatIsJSONP, formatIsXML, getAuthenticatedUser, getCallback, getColumnHeaderStyle, getDefaultOutput, getExtension, getFormat, getIntParameter, getIntParameter, getLineBreak, getListManager, getOptionalParameter, getOptionalParameter, getPermission, getProperty, getRawOutput, getRequestFileName, getRequiredParameter, hasCallback, initState, isAuthenticated, isGzip, isUncompressed, isZip, makeJSONOutput, makeXMLOutput, postInit, service, setFormat, setNameSpace, validateState, wantsColumnHeaders, wantsDataPackage
-
-
-
-
Method Detail
-
getPrintWriter
public java.io.PrintWriter getPrintWriter()
- Returns:
- print writer
-
getOutputStream
public java.io.OutputStream getOutputStream()
- Returns:
- output stream
-
getDefaultFileName
protected java.lang.String getDefaultFileName()
- Overrides:
getDefaultFileNamein classorg.intermine.webservice.server.WebService
-
getSuffix
protected abstract java.lang.String getSuffix()
- Returns:
- suffix
-
getContentType
protected abstract java.lang.String getContentType()
- Returns:
- content type
-
getDefaultOutput
protected org.intermine.webservice.server.output.Output getDefaultOutput(java.io.PrintWriter out, java.io.OutputStream outputstream, java.lang.String sep)- Overrides:
getDefaultOutputin classorg.intermine.webservice.server.WebService
-
getDefaultFormat
public org.intermine.webservice.server.Format getDefaultFormat()
- Overrides:
getDefaultFormatin classorg.intermine.webservice.server.WebService
-
getQuery
protected org.intermine.pathquery.PathQuery getQuery()
Return the query specified in the request, shorn of all duplicate classes in the view. Note, it is the users responsibility to ensure that there are only SequenceFeatures in the view.- Returns:
- A query.
-
getExporter
protected abstract org.intermine.web.logic.export.Exporter getExporter(org.intermine.pathquery.PathQuery pq)
- Parameters:
pq- pathquery- Returns:
- exporter
-
checkPathQuery
protected void checkPathQuery(org.intermine.pathquery.PathQuery pq) throws java.lang.ExceptionNo-op stub. Put query validation here.- Parameters:
pq- pathquery- Throws:
java.lang.Exception- if something goes wrong
-
execute
protected void execute() throws java.lang.Exception- Specified by:
executein classorg.intermine.webservice.server.WebService- Throws:
java.lang.Exception
-
getPathQueryViews
protected static java.util.List<java.lang.String> getPathQueryViews(java.lang.String[] views)
Parse path query views from request parameter "view" comma-separated- Parameters:
views- views in pathquery- Returns:
- a list of query view as string
-
getQueryPaths
protected java.util.List<org.intermine.pathquery.Path> getQueryPaths(org.intermine.pathquery.PathQuery pq)
Parse view strings to Path objects- Parameters:
pq- pathquery- Returns:
- a list of query path
-
-