Class HttpConsoleOperation

    • Constructor Summary

      Constructors 
      Constructor Description
      HttpConsoleOperation​(java.lang.String relativePath)
      Pass the relative path of the "console" page, take a look at the implementation of TenantConsole class
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      org.jsoup.nodes.Element execute​(org.apache.http.message.BasicNameValuePair command)
      This is the method that will perform the actual POST command on alfresco console
      protected org.jsoup.nodes.Document fullResponseDocument()
      Perform the get request on console page.
      protected java.lang.String getAdminBasicAuthentication()  
      protected java.lang.String getAlfrescoConsolePath()  
      org.apache.http.impl.client.CloseableHttpClient getHttpClient()  
      protected org.jsoup.nodes.Element parsedResponse()  
      • Methods inherited from class java.lang.Object

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

      • LOG

        protected static org.slf4j.Logger LOG
      • relativePath

        protected java.lang.String relativePath
    • Constructor Detail

      • HttpConsoleOperation

        public HttpConsoleOperation​(java.lang.String relativePath)
        Pass the relative path of the "console" page, take a look at the implementation of TenantConsole class
        Parameters:
        relativePath -
    • Method Detail

      • getHttpClient

        public org.apache.http.impl.client.CloseableHttpClient getHttpClient()
        Returns:
        HTTP Client used in POST calls
      • getAlfrescoConsolePath

        protected java.lang.String getAlfrescoConsolePath()
        Returns:
        the full path (server & relative path) of console page
      • getAdminBasicAuthentication

        protected java.lang.String getAdminBasicAuthentication()
        Returns:
        Basic Authentication 64 bit encoded of admin user (defined in *.properties file)
      • execute

        public org.jsoup.nodes.Element execute​(org.apache.http.message.BasicNameValuePair command)
                                        throws java.lang.Exception
        This is the method that will perform the actual POST command on alfresco console
        Returns:
        Throws:
        java.lang.Exception
      • fullResponseDocument

        protected org.jsoup.nodes.Document fullResponseDocument()
                                                         throws java.lang.Exception
        Perform the get request on console page.
        Returns:
        Document object with entire HTML page
        Throws:
        java.lang.Exception
      • parsedResponse

        protected org.jsoup.nodes.Element parsedResponse()
                                                  throws java.lang.Exception
        Returns:
        the response value parsed
        Throws:
        java.lang.Exception