Class QueryResultLinkGenerator


  • public class QueryResultLinkGenerator
    extends LinkGeneratorBase
    Class that implements generating links for QueryResultService web service.
    Author:
    Jakub Kulaviak
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      java.lang.String getLink​(java.lang.String baseUrl, java.lang.String queryXml, java.lang.String resultFormat)
      Generates QueryResultService web service link.
      java.lang.String getLinkPath​(java.lang.String queryXml, java.lang.String resultFormat)
      Get the link path for a query.
      java.lang.String getMineResultsLink​(java.lang.String baseUrl, java.lang.String queryXml)
      Get the link for a query that shows the results in a mine.
      java.lang.String getMineResultsPath​(java.lang.String queryXml)
      Get the link path for a query that shows the results in a mine.
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • QueryResultLinkGenerator

        public QueryResultLinkGenerator()
    • Method Detail

      • getLink

        public java.lang.String getLink​(java.lang.String baseUrl,
                                        java.lang.String queryXml,
                                        java.lang.String resultFormat)
        Generates QueryResultService web service link.
        Parameters:
        baseUrl - base url e.g. http://www.flymine.org/release-12.0
        queryXml - query xml
        resultFormat - result format
        Returns:
        generated link
      • getLinkPath

        public java.lang.String getLinkPath​(java.lang.String queryXml,
                                            java.lang.String resultFormat)
        Get the link path for a query.
        Parameters:
        queryXml - The query represented as XML.
        resultFormat - The desired result format.
        Returns:
        A string representing the path section of a webservice URL.
      • getMineResultsLink

        public java.lang.String getMineResultsLink​(java.lang.String baseUrl,
                                                   java.lang.String queryXml)
        Get the link for a query that shows the results in a mine.
        Parameters:
        baseUrl - The base URL of the mine.
        queryXml - The query represented as XML.
        Returns:
        A string representing a web-app URL.
      • getMineResultsPath

        public java.lang.String getMineResultsPath​(java.lang.String queryXml)
        Get the link path for a query that shows the results in a mine.
        Parameters:
        queryXml - The query represented as XML.
        Returns:
        A string representing the path section of a web-app URL.