Package x.data.skydb

Class SkyDBWebServiceManager

java.lang.Object
x.data.skydb.SkyDBWebServiceManager

public class SkyDBWebServiceManager extends Object
Used at Swing, JSF or other client for call SkyLogicSystem's service. In JSF or other web framework should keep this class in session for keep connection session.
Author:
Sakdsitt Likhitmetagool
  • Constructor Details

    • SkyDBWebServiceManager

      public SkyDBWebServiceManager()
      Constructor part.
    • SkyDBWebServiceManager

      public SkyDBWebServiceManager(String site, int port, String protocol)
  • Method Details

    • initClientServiceConnection

      public void initClientServiceConnection()
      Initial HTTP client session by set URL of SkyLogicSystem's host.
    • initClientServiceConnection

      public void initClientServiceConnection(String host, int port, String scheme)
    • setServerHost

      public void setServerHost(String host, int port, String scheme)
      Add URL SkyLogicSystem's host that need to get data from it.
    • setServerHost

      public void setServerHost(String host, int port, String scheme, String basicAuthenKey)
      Add URL SkyLogicSystem's host that need to get data from it.
    • setServerHost

      public void setServerHost(org.apache.http.HttpHost httpHostObj)
      xxxx.
    • getHttpHost

      public org.apache.http.HttpHost getHttpHost()
      xxxx.
    • setHttpHostURL

      public void setHttpHostURL(String url)
      xxxx.
    • getURL

      public String getURL(String url)
      xxxx.
    • loginServerService

      public boolean loginServerService(String url, String username, String password) throws Exception
      Login SkyLogicSystem's service session.
      Throws:
      Exception
    • logoutServerService

      public boolean logoutServerService(String url) throws Exception
      Logout SkyLogicSystem's service session.
      Throws:
      Exception
    • executeServerService

      public String executeServerService(String url) throws Exception
      Call SkyLogicSystem's service session by use GET method.
      Throws:
      Exception
    • httpGetMethod

      public String httpGetMethod(String url) throws IOException
      Call SkyLogicSystem's service session by use GET method.
      Throws:
      IOException
    • httpPostMethod

      public String httpPostMethod(String url, String str_input) throws IOException
      Call SkyLogicSystem's service session by use POST method. The Input type is String.
      Throws:
      IOException
    • httpPostMethod

      public String httpPostMethod(String url, String str_input1, String str_input2) throws IOException
      Call SkyLogicSystem's service session by use POST method. The Input type is String.
      Throws:
      IOException
    • httpPostMethod

      public String httpPostMethod(String url, String str_input1, String str_input2, String str_input3) throws IOException
      Call SkyLogicSystem's service session by use POST method. The Input type is String.
      Throws:
      IOException
    • httpPostMethod2

      public String httpPostMethod2(String url, String str_input) throws IOException
      Call SkyLogicSystem's service session by use POST method. The Input type is String.
      Throws:
      IOException
    • httpPostMethod

      public String httpPostMethod(String url, org.apache.http.NameValuePair[] valuePair) throws IOException
      Call SkyLogicSystem's service session by use POST method. The input is values map.
      Throws:
      IOException
    • fileUpload

      public String fileUpload(String url, okhttp3.MultipartReader.Part[] partValuePair) throws IOException
      Call SkyLogicSystem's service session by use File Upload method.
      Throws:
      IOException
    • httpPutMethod

      public String httpPutMethod(String url, String xml) throws IOException
      Call SkyLogicSystem's service session by use PUT method.
      Throws:
      IOException
    • httpDeleteMethod

      public String httpDeleteMethod(String url) throws IOException
      Call SkyLogicSystem's service session by use DELETE method.
      Throws:
      IOException