Class ServerRequestInfo

  • All Implemented Interfaces:
    org.gcube.informationsystem.resourceregistry.api.request.RequestInfo

    public class ServerRequestInfo
    extends Object
    implements org.gcube.informationsystem.resourceregistry.api.request.RequestInfo
    Author:
    Luca Frosini (ISTI - CNR)
    • Field Detail

      • logger

        protected static org.slf4j.Logger logger
      • uriInfo

        protected javax.ws.rs.core.UriInfo uriInfo
      • includeMeta

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

        protected boolean allMeta
        Track if the request requested to include Metadata in all IdentifiableElement or just in the root instance
      • hierarchicalMode

        protected boolean hierarchicalMode
        Track if hierarchicalMode has been requested
      • includeContexts

        protected boolean includeContexts
        Track if the request requested to include contexts
    • Constructor Detail

      • ServerRequestInfo

        public ServerRequestInfo()
    • Method Detail

      • getUriInfo

        public javax.ws.rs.core.UriInfo getUriInfo()
      • isAllowed

        public boolean isAllowed​(String queryParameterKey)
        -check if the user is allowed to set such a request
        Parameters:
        queryParameterKey - requested query parameter
        Returns:
        true is the user is allowed to set such a request
      • setIfAllowed

        public boolean setIfAllowed​(String queryParameterKey,
                                    boolean bool)
        Set the parameter if the user is allowed otherwise the default is maintained
        Parameters:
        queryParameterKey - requested query parameter
        bool - the value to set
        Returns:
        the value of variable corresponding the request parameter independetly if the value has been set.
      • checkQueryParameter

        public void checkQueryParameter​(String queryParameterKey)
      • setUriInfo

        public void setUriInfo​(javax.ws.rs.core.UriInfo uriInfo)
      • checkAllQueryParameters

        public void checkAllQueryParameters()
      • checkIncludeQueryParameters

        public void checkIncludeQueryParameters()
      • checkIncludeAllMetaQueryParameters

        public void checkIncludeAllMetaQueryParameters()
      • 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
      • 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