Package org.intermine.bio.webservice
Class AbstractRegionExportService
- java.lang.Object
-
- org.intermine.webservice.server.WebService
-
- org.intermine.webservice.server.core.JSONService
-
- org.intermine.webservice.server.lists.AbstractListService
-
- org.intermine.webservice.server.lists.AuthenticatedListService
-
- org.intermine.webservice.server.lists.ListMakerService
-
- org.intermine.bio.webservice.GenomicRegionSearchService
-
- org.intermine.bio.webservice.AbstractRegionExportService
-
- Direct Known Subclasses:
GenomicRegionBedService,GenomicRegionFastaService,GenomicRegionGFF3Service
public abstract class AbstractRegionExportService extends GenomicRegionSearchService
Base class for Biological region export services.
-
-
Constructor Summary
Constructors Constructor Description AbstractRegionExportService(org.intermine.api.InterMineAPI im)Constructor.
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description protected voidcheckPathQuery(org.intermine.pathquery.PathQuery pq)No-op stub.protected voidexport(org.intermine.pathquery.PathQuery pq, org.intermine.api.profile.Profile profile)Method that carries out the logic for this exporter.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 separator)protected abstract org.intermine.web.logic.export.ExportergetExporter(org.intermine.pathquery.PathQuery pq)protected org.intermine.webservice.server.output.FormattergetFormatter()protected java.io.OutputStreamgetOutputStream()protected java.io.PrintWritergetPrintWriter()protected abstract java.lang.StringgetSuffix()booleanisAuthenticated()protected voidmakeList(org.intermine.webservice.server.lists.ListInput input, java.lang.String type, org.intermine.api.profile.Profile profile, java.util.Set<java.lang.String> temporaryBagNamesAccumulator)protected org.intermine.pathquery.PathQuerymakePathQuery(java.lang.String type, java.util.Collection<java.lang.Integer> ids)Make a path-query from a bag.protected voidvalidateState()-
Methods inherited from class org.intermine.bio.webservice.GenomicRegionSearchService
createQueries, doListCreation, getHeaderAttributes, getInput, getNewListType
-
Methods inherited from class org.intermine.webservice.server.lists.ListMakerService
canServe, execute, initialiseDelendumAccumulator
-
Methods inherited from class org.intermine.webservice.server.lists.AbstractListService
getClassesForBags
-
Methods inherited from class org.intermine.webservice.server.core.JSONService
addOutputInfo, addResultEntries, addResultEntries, addResultEntry, addResultEntry, addResultItem, addResultItem, addResultValue, addResultValue, addResultValue, getResultsKey, lazyList, postInit
-
Methods inherited from class org.intermine.webservice.server.WebService
cleanUp, formatIsFlatFile, formatIsJSON, formatIsJSONP, formatIsXML, getAuthenticatedUser, getCallback, getColumnHeaderStyle, getDefaultOutput, getExtension, getFormat, getIntParameter, getIntParameter, getLineBreak, getListManager, getOptionalParameter, getOptionalParameter, getPermission, getProperty, getRawOutput, getRequestFileName, getRequiredParameter, hasCallback, initState, isGzip, isUncompressed, isZip, makeJSONOutput, makeXMLOutput, service, setFormat, setNameSpace, wantsColumnHeaders, wantsDataPackage
-
-
-
-
Method Detail
-
isAuthenticated
public boolean isAuthenticated()
- Overrides:
isAuthenticatedin classorg.intermine.webservice.server.WebService
-
validateState
protected void validateState()
- Overrides:
validateStatein classorg.intermine.webservice.server.lists.ListMakerService
-
makeList
protected void makeList(org.intermine.webservice.server.lists.ListInput input, java.lang.String type, org.intermine.api.profile.Profile profile, java.util.Set<java.lang.String> temporaryBagNamesAccumulator) throws java.lang.Exception- Overrides:
makeListin classGenomicRegionSearchService- Throws:
java.lang.Exception
-
makePathQuery
protected org.intermine.pathquery.PathQuery makePathQuery(java.lang.String type, java.util.Collection<java.lang.Integer> ids) throws java.lang.ExceptionMake a path-query from a bag.- Parameters:
ids- list of idstype- The bag to constrain this query on.- Returns:
- A path-query.
- Throws:
java.lang.Exception- if something goes wrong
-
checkPathQuery
protected void checkPathQuery(org.intermine.pathquery.PathQuery pq) throws java.lang.ExceptionNo-op stub. Override to implement format checks.- Parameters:
pq- pathquery- Throws:
java.lang.Exception- if something goes wrong
-
getExporter
protected abstract org.intermine.web.logic.export.Exporter getExporter(org.intermine.pathquery.PathQuery pq)
- Parameters:
pq- pathquery- Returns:
- the exporter
-
export
protected void export(org.intermine.pathquery.PathQuery pq, org.intermine.api.profile.Profile profile)Method that carries out the logic for this exporter.- Parameters:
pq- The pathquery.profile- A profile to lookup saved bags in.
-
getSuffix
protected abstract java.lang.String getSuffix()
- Returns:
- The suffix for the file name.
-
getDefaultFileName
protected java.lang.String getDefaultFileName()
- Overrides:
getDefaultFileNamein classorg.intermine.webservice.server.WebService
-
getPrintWriter
protected java.io.PrintWriter getPrintWriter()
- Returns:
- printwriter
-
getOutputStream
protected java.io.OutputStream getOutputStream()
- Returns:
- outputstream
-
getContentType
protected abstract java.lang.String getContentType()
- Returns:
- content type
-
getFormatter
protected org.intermine.webservice.server.output.Formatter getFormatter()
- Returns:
- formatter
-
getDefaultOutput
protected org.intermine.webservice.server.output.Output getDefaultOutput(java.io.PrintWriter out, java.io.OutputStream outputstream, java.lang.String separator)- Overrides:
getDefaultOutputin classorg.intermine.webservice.server.WebService
-
getDefaultFormat
public org.intermine.webservice.server.Format getDefaultFormat()
- Overrides:
getDefaultFormatin classorg.intermine.webservice.server.lists.ListMakerService
-
-