Class RestEnterpriseSearchService

    • Constructor Detail

      • RestEnterpriseSearchService

        public RestEnterpriseSearchService()
    • Method Detail

      • findByParameters

        @POST
        @Path("/findByParameters")
        public com.logicaldoc.webservice.model.WSDocument[] findByParameters​(@QueryParam("templateId")
                                                                             Long templateId,
                                                                             WSCriterion[] criteria,
                                                                             @QueryParam("order")
                                                                             String order,
                                                                             @QueryParam("maxResults")
                                                                             Integer maxResults)
                                                                      throws Exception
        Description copied from interface: EnterpriseSearchService
        Allows a user to retrieve all documents that match the list of criteria and that belong to the template with the given identifier. It also retrieves regular documents and aliases.
        Specified by:
        findByParameters in interface EnterpriseSearchService
        Parameters:
        templateId - the type of documents to be retrieved
        criteria - an array of search criteria that must be met
        order - optional order expression (eg. creation desc)
        maxResults - maximum number of results
        Returns:
        Collection of found documents
        Throws:
        Exception - error in the server application
      • findDocumentsByParameters

        @POST
        @Path("/findDocumentsByParameters")
        public com.logicaldoc.webservice.model.WSDocument[] findDocumentsByParameters​(@QueryParam("templateId")
                                                                                      Long templateId,
                                                                                      WSCriterion[] criteria,
                                                                                      @QueryParam("order")
                                                                                      String order,
                                                                                      @QueryParam("maxResults")
                                                                                      Integer maxResults)
                                                                               throws Exception
        Description copied from interface: EnterpriseSearchService
        Allows a user to retrieve all documents that match the list of criteria and that belong to the template with the given identifier. Retrieves only regular documents.
        Specified by:
        findDocumentsByParameters in interface EnterpriseSearchService
        Parameters:
        templateId - the type of documents to be retrieved
        criteria - an array of search criteria that must be met
        order - optional order expression (eg. creation desc)
        maxResults - maximum number of results
        Returns:
        Collection of found documents
        Throws:
        Exception - error in the server application
      • queryDocuments

        @POST
        @Path("/queryDocuments")
        @Consumes("application/x-www-form-urlencoded")
        public String[][] queryDocuments​(@FormParam("select")
                                         String select,
                                         @FormParam("tables")
                                         String tables,
                                         @FormParam("where")
                                         String where,
                                         @FormParam("order")
                                         String order,
                                         @FormParam("maxResults")
                                         Integer maxResults)
                                  throws Exception
        Description copied from interface: EnterpriseSearchService
        Queries the database to search for documents. The query is composed as: SELECT $select FROM ld_document DOC $tables WHERE $where $order;
        Specified by:
        queryDocuments in interface EnterpriseSearchService
        Parameters:
        select - columns to return
        tables - additional tables to join with ld_doument
        where - query conditions
        order - optional clause for ordering or grouping the results
        maxResults - maximum number of results
        Returns:
        Collection of found folders
        Throws:
        Exception - error in the server application