Class AbstractClient

  • All Implemented Interfaces:
    Client
    Direct Known Subclasses:
    RemoteClient

    public abstract class AbstractClient
    extends java.lang.Object
    implements Client
    Abstract base class for client implementations.

    A general purpose but very useful RemoteClient implementation is provided that should handle most HTTP(S) connection needs.

    Client objects manage state between the web script layer and the remote endpoint.

    Connector objects tell the Client objects what to do and when. They orchestrate the sequence of handshakes and so forth so that the end user or developer doesn't need to worry about the underlying mechanics remoting to the endpoint.

    Author:
    muzquiano, Kevin Roast
    • Field Summary

      Fields 
      Modifier and Type Field Description
      protected java.lang.String endpoint  
    • Constructor Summary

      Constructors 
      Constructor Description
      AbstractClient()  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      java.lang.String getEndpoint()  
      java.net.URL getURL()  
      void setEndpoint​(java.lang.String endpoint)
      Set the endpoint for the Client instance
      • Methods inherited from class java.lang.Object

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

      • endpoint

        protected java.lang.String endpoint
    • Constructor Detail

      • AbstractClient

        public AbstractClient()
    • Method Detail

      • setEndpoint

        public void setEndpoint​(java.lang.String endpoint)
        Set the endpoint for the Client instance
        Parameters:
        endpoint - Endpoint URL stem
      • getEndpoint

        public java.lang.String getEndpoint()
        Specified by:
        getEndpoint in interface Client
        Returns:
        the Endpoint for this Client e.g. http://localhost:8080/alfresco/service
      • getURL

        public java.net.URL getURL()
        Specified by:
        getURL in interface Client
        Returns:
        the Endpoint for the Client as a URL object