Class ResourceRegistryQueryTemplateClientImpl

    • Field Summary

      Fields 
      Modifier and Type Field Description
      protected String address  
      protected boolean allMeta
      Track if the client must request to include Metadata in all IdentifiableElement or just in the root instance
      protected Map<String,​String> headers  
      protected boolean hierarchicalMode
      Track if the client must request the hierarchicalMode
      protected boolean includeContexts
      Track if the client must request to include contexts
      protected boolean includeMeta
      Track if the client must request to include Metadata
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      void addHeader​(String name, String value)  
      List<org.gcube.informationsystem.queries.templates.reference.entities.QueryTemplate> all()  
      boolean allMeta()  
      String create​(String queryTemplate)  
      org.gcube.informationsystem.queries.templates.reference.entities.QueryTemplate create​(org.gcube.informationsystem.queries.templates.reference.entities.QueryTemplate queryTemplate)  
      boolean delete​(String queryTemplateName)  
      boolean delete​(org.gcube.informationsystem.queries.templates.reference.entities.QueryTemplate queryTemplate)  
      boolean exist​(String queryTemplateName)  
      boolean exist​(org.gcube.informationsystem.queries.templates.reference.entities.QueryTemplate queryTemplate)  
      protected org.gcube.common.gxhttp.request.GXHTTPStringRequest getGXHTTPStringRequest()  
      boolean includeContexts()  
      boolean includeMeta()  
      boolean isHierarchicalMode()  
      org.gcube.informationsystem.queries.templates.reference.entities.QueryTemplate read​(String queryTemplateName)  
      org.gcube.informationsystem.queries.templates.reference.entities.QueryTemplate read​(org.gcube.informationsystem.queries.templates.reference.entities.QueryTemplate queryTemplate)  
      String readAsString​(String queryTemplateName)  
      <E extends org.gcube.informationsystem.model.reference.ERElement>
      List<E>
      run​(String name)  
      String run​(String name, String params)  
      <E extends org.gcube.informationsystem.model.reference.ERElement>
      List<E>
      run​(String name, org.gcube.com.fasterxml.jackson.databind.JsonNode jsonNode)  
      <E extends org.gcube.informationsystem.model.reference.ERElement>
      List<E>
      run​(org.gcube.informationsystem.queries.templates.reference.entities.QueryTemplate queryTemplate)  
      <E extends org.gcube.informationsystem.model.reference.ERElement>
      List<E>
      run​(org.gcube.informationsystem.queries.templates.reference.entities.QueryTemplate queryTemplate, org.gcube.com.fasterxml.jackson.databind.JsonNode jsonNode)  
      String runGetString​(String name)  
      void setAllMeta​(boolean allMeta)  
      void setHierarchicalMode​(boolean hierarchicalMode)  
      void setIncludeContexts​(boolean includeContexts)  
      void setIncludeMeta​(boolean includeMeta)  
      String update​(String queryTemplate)  
      org.gcube.informationsystem.queries.templates.reference.entities.QueryTemplate update​(org.gcube.informationsystem.queries.templates.reference.entities.QueryTemplate queryTemplate)  
    • Field Detail

      • address

        protected final String address
      • hierarchicalMode

        protected boolean hierarchicalMode
        Track if the client must request the hierarchicalMode
      • includeContexts

        protected boolean includeContexts
        Track if the client must request to include contexts
      • includeMeta

        protected boolean includeMeta
        Track if the client must request to include Metadata
      • allMeta

        protected boolean allMeta
        Track if the client must request to include Metadata in all IdentifiableElement or just in the root instance
    • Constructor Detail

      • ResourceRegistryQueryTemplateClientImpl

        public ResourceRegistryQueryTemplateClientImpl​(String address)
    • Method Detail

      • isHierarchicalMode

        public boolean isHierarchicalMode()
        Specified by:
        isHierarchicalMode in interface org.gcube.informationsystem.resourceregistry.api.request.RequestInfo
      • setHierarchicalMode

        public void setHierarchicalMode​(boolean hierarchicalMode)
        Specified by:
        setHierarchicalMode in interface org.gcube.informationsystem.resourceregistry.api.request.RequestInfo
      • includeContexts

        public boolean includeContexts()
        Specified by:
        includeContexts in interface org.gcube.informationsystem.resourceregistry.api.request.RequestInfo
      • setIncludeContexts

        public void setIncludeContexts​(boolean includeContexts)
        Specified by:
        setIncludeContexts in interface org.gcube.informationsystem.resourceregistry.api.request.RequestInfo
      • includeMeta

        public boolean includeMeta()
        Specified by:
        includeMeta in interface org.gcube.informationsystem.resourceregistry.api.request.RequestInfo
      • setIncludeMeta

        public void setIncludeMeta​(boolean includeMeta)
        Specified by:
        setIncludeMeta in interface org.gcube.informationsystem.resourceregistry.api.request.RequestInfo
      • allMeta

        public boolean allMeta()
        Specified by:
        allMeta in interface org.gcube.informationsystem.resourceregistry.api.request.RequestInfo
      • setAllMeta

        public void setAllMeta​(boolean allMeta)
        Specified by:
        setAllMeta in interface org.gcube.informationsystem.resourceregistry.api.request.RequestInfo
      • getGXHTTPStringRequest

        protected org.gcube.common.gxhttp.request.GXHTTPStringRequest getGXHTTPStringRequest()
      • all

        public List<org.gcube.informationsystem.queries.templates.reference.entities.QueryTemplate> all()
                                                                                                 throws org.gcube.informationsystem.resourceregistry.api.exceptions.ResourceRegistryException
        Specified by:
        all in interface ResourceRegistryQueryTemplateClient
        Throws:
        org.gcube.informationsystem.resourceregistry.api.exceptions.ResourceRegistryException
      • create

        public org.gcube.informationsystem.queries.templates.reference.entities.QueryTemplate create​(org.gcube.informationsystem.queries.templates.reference.entities.QueryTemplate queryTemplate)
                                                                                              throws org.gcube.informationsystem.resourceregistry.api.exceptions.queries.templates.QueryTemplateAlreadyPresentException,
                                                                                                     org.gcube.informationsystem.resourceregistry.api.exceptions.ResourceRegistryException
        Specified by:
        create in interface ResourceRegistryQueryTemplateClient
        Throws:
        org.gcube.informationsystem.resourceregistry.api.exceptions.queries.templates.QueryTemplateAlreadyPresentException
        org.gcube.informationsystem.resourceregistry.api.exceptions.ResourceRegistryException
      • create

        public String create​(String queryTemplate)
                      throws org.gcube.informationsystem.resourceregistry.api.exceptions.queries.templates.QueryTemplateAlreadyPresentException,
                             org.gcube.informationsystem.resourceregistry.api.exceptions.ResourceRegistryException
        Specified by:
        create in interface ResourceRegistryQueryTemplateClient
        Throws:
        org.gcube.informationsystem.resourceregistry.api.exceptions.queries.templates.QueryTemplateAlreadyPresentException
        org.gcube.informationsystem.resourceregistry.api.exceptions.ResourceRegistryException
      • exist

        public boolean exist​(String queryTemplateName)
                      throws org.gcube.informationsystem.resourceregistry.api.exceptions.ResourceRegistryException
        Specified by:
        exist in interface ResourceRegistryQueryTemplateClient
        Throws:
        org.gcube.informationsystem.resourceregistry.api.exceptions.ResourceRegistryException
      • exist

        public boolean exist​(org.gcube.informationsystem.queries.templates.reference.entities.QueryTemplate queryTemplate)
                      throws org.gcube.informationsystem.resourceregistry.api.exceptions.ResourceRegistryException
        Specified by:
        exist in interface ResourceRegistryQueryTemplateClient
        Throws:
        org.gcube.informationsystem.resourceregistry.api.exceptions.ResourceRegistryException
      • read

        public org.gcube.informationsystem.queries.templates.reference.entities.QueryTemplate read​(org.gcube.informationsystem.queries.templates.reference.entities.QueryTemplate queryTemplate)
                                                                                            throws org.gcube.informationsystem.resourceregistry.api.exceptions.queries.templates.QueryTemplateNotFoundException,
                                                                                                   org.gcube.informationsystem.resourceregistry.api.exceptions.ResourceRegistryException
        Specified by:
        read in interface ResourceRegistryQueryTemplateClient
        Throws:
        org.gcube.informationsystem.resourceregistry.api.exceptions.queries.templates.QueryTemplateNotFoundException
        org.gcube.informationsystem.resourceregistry.api.exceptions.ResourceRegistryException
      • read

        public org.gcube.informationsystem.queries.templates.reference.entities.QueryTemplate read​(String queryTemplateName)
                                                                                            throws org.gcube.informationsystem.resourceregistry.api.exceptions.queries.templates.QueryTemplateNotFoundException,
                                                                                                   org.gcube.informationsystem.resourceregistry.api.exceptions.ResourceRegistryException
        Specified by:
        read in interface ResourceRegistryQueryTemplateClient
        Throws:
        org.gcube.informationsystem.resourceregistry.api.exceptions.queries.templates.QueryTemplateNotFoundException
        org.gcube.informationsystem.resourceregistry.api.exceptions.ResourceRegistryException
      • readAsString

        public String readAsString​(String queryTemplateName)
                            throws org.gcube.informationsystem.resourceregistry.api.exceptions.queries.templates.QueryTemplateNotFoundException,
                                   org.gcube.informationsystem.resourceregistry.api.exceptions.ResourceRegistryException
        Specified by:
        readAsString in interface ResourceRegistryQueryTemplateClient
        Throws:
        org.gcube.informationsystem.resourceregistry.api.exceptions.queries.templates.QueryTemplateNotFoundException
        org.gcube.informationsystem.resourceregistry.api.exceptions.ResourceRegistryException
      • update

        public org.gcube.informationsystem.queries.templates.reference.entities.QueryTemplate update​(org.gcube.informationsystem.queries.templates.reference.entities.QueryTemplate queryTemplate)
                                                                                              throws org.gcube.informationsystem.resourceregistry.api.exceptions.queries.templates.QueryTemplateNotFoundException,
                                                                                                     org.gcube.informationsystem.resourceregistry.api.exceptions.ResourceRegistryException
        Specified by:
        update in interface ResourceRegistryQueryTemplateClient
        Throws:
        org.gcube.informationsystem.resourceregistry.api.exceptions.queries.templates.QueryTemplateNotFoundException
        org.gcube.informationsystem.resourceregistry.api.exceptions.ResourceRegistryException
      • update

        public String update​(String queryTemplate)
                      throws org.gcube.informationsystem.resourceregistry.api.exceptions.queries.templates.QueryTemplateNotFoundException,
                             org.gcube.informationsystem.resourceregistry.api.exceptions.ResourceRegistryException
        Specified by:
        update in interface ResourceRegistryQueryTemplateClient
        Throws:
        org.gcube.informationsystem.resourceregistry.api.exceptions.queries.templates.QueryTemplateNotFoundException
        org.gcube.informationsystem.resourceregistry.api.exceptions.ResourceRegistryException
      • runGetString

        public String runGetString​(String name)
                            throws org.gcube.informationsystem.resourceregistry.api.exceptions.queries.templates.QueryTemplateNotFoundException,
                                   org.gcube.informationsystem.resourceregistry.api.exceptions.ResourceRegistryException
        Specified by:
        runGetString in interface ResourceRegistryQueryTemplateClient
        Throws:
        org.gcube.informationsystem.resourceregistry.api.exceptions.queries.templates.QueryTemplateNotFoundException
        org.gcube.informationsystem.resourceregistry.api.exceptions.ResourceRegistryException
      • run

        public <E extends org.gcube.informationsystem.model.reference.ERElement> List<E> run​(String name)
                                                                                      throws org.gcube.informationsystem.resourceregistry.api.exceptions.queries.templates.QueryTemplateNotFoundException,
                                                                                             org.gcube.informationsystem.resourceregistry.api.exceptions.ResourceRegistryException
        Specified by:
        run in interface ResourceRegistryQueryTemplateClient
        Throws:
        org.gcube.informationsystem.resourceregistry.api.exceptions.queries.templates.QueryTemplateNotFoundException
        org.gcube.informationsystem.resourceregistry.api.exceptions.ResourceRegistryException
      • run

        public <E extends org.gcube.informationsystem.model.reference.ERElement> List<E> run​(org.gcube.informationsystem.queries.templates.reference.entities.QueryTemplate queryTemplate)
                                                                                      throws org.gcube.informationsystem.resourceregistry.api.exceptions.queries.templates.QueryTemplateNotFoundException,
                                                                                             org.gcube.informationsystem.resourceregistry.api.exceptions.ResourceRegistryException
        Specified by:
        run in interface ResourceRegistryQueryTemplateClient
        Throws:
        org.gcube.informationsystem.resourceregistry.api.exceptions.queries.templates.QueryTemplateNotFoundException
        org.gcube.informationsystem.resourceregistry.api.exceptions.ResourceRegistryException
      • run

        public String run​(String name,
                          String params)
                   throws org.gcube.informationsystem.resourceregistry.api.exceptions.queries.templates.QueryTemplateNotFoundException,
                          org.gcube.informationsystem.resourceregistry.api.exceptions.ResourceRegistryException
        Specified by:
        run in interface ResourceRegistryQueryTemplateClient
        Throws:
        org.gcube.informationsystem.resourceregistry.api.exceptions.queries.templates.QueryTemplateNotFoundException
        org.gcube.informationsystem.resourceregistry.api.exceptions.ResourceRegistryException
      • run

        public <E extends org.gcube.informationsystem.model.reference.ERElement> List<E> run​(String name,
                                                                                             org.gcube.com.fasterxml.jackson.databind.JsonNode jsonNode)
                                                                                      throws org.gcube.informationsystem.resourceregistry.api.exceptions.queries.templates.QueryTemplateNotFoundException,
                                                                                             org.gcube.informationsystem.resourceregistry.api.exceptions.ResourceRegistryException
        Specified by:
        run in interface ResourceRegistryQueryTemplateClient
        Throws:
        org.gcube.informationsystem.resourceregistry.api.exceptions.queries.templates.QueryTemplateNotFoundException
        org.gcube.informationsystem.resourceregistry.api.exceptions.ResourceRegistryException
      • run

        public <E extends org.gcube.informationsystem.model.reference.ERElement> List<E> run​(org.gcube.informationsystem.queries.templates.reference.entities.QueryTemplate queryTemplate,
                                                                                             org.gcube.com.fasterxml.jackson.databind.JsonNode jsonNode)
                                                                                      throws org.gcube.informationsystem.resourceregistry.api.exceptions.queries.templates.QueryTemplateNotFoundException,
                                                                                             org.gcube.informationsystem.resourceregistry.api.exceptions.ResourceRegistryException
        Specified by:
        run in interface ResourceRegistryQueryTemplateClient
        Throws:
        org.gcube.informationsystem.resourceregistry.api.exceptions.queries.templates.QueryTemplateNotFoundException
        org.gcube.informationsystem.resourceregistry.api.exceptions.ResourceRegistryException
      • delete

        public boolean delete​(org.gcube.informationsystem.queries.templates.reference.entities.QueryTemplate queryTemplate)
                       throws org.gcube.informationsystem.resourceregistry.api.exceptions.queries.templates.QueryTemplateNotFoundException,
                              org.gcube.informationsystem.resourceregistry.api.exceptions.ResourceRegistryException
        Specified by:
        delete in interface ResourceRegistryQueryTemplateClient
        Throws:
        org.gcube.informationsystem.resourceregistry.api.exceptions.queries.templates.QueryTemplateNotFoundException
        org.gcube.informationsystem.resourceregistry.api.exceptions.ResourceRegistryException
      • delete

        public boolean delete​(String queryTemplateName)
                       throws org.gcube.informationsystem.resourceregistry.api.exceptions.queries.templates.QueryTemplateNotFoundException,
                              org.gcube.informationsystem.resourceregistry.api.exceptions.ResourceRegistryException
        Specified by:
        delete in interface ResourceRegistryQueryTemplateClient
        Throws:
        org.gcube.informationsystem.resourceregistry.api.exceptions.queries.templates.QueryTemplateNotFoundException
        org.gcube.informationsystem.resourceregistry.api.exceptions.ResourceRegistryException