Interface RemoteClient

All Superinterfaces:
ConnectionRequest

public interface RemoteClient extends ConnectionRequest
Contains basic information about a remote client
  • Method Details

    • connectionRequest

      ConnectionRequest connectionRequest()
      Returns:
      the initial connection request this client is based on
    • creationTime

      LocalDateTime creationTime()
      Returns:
      the time when this client connection was created
    • databaseUser

      User databaseUser()
      Returns:
      the user used when connecting to the underlying database
    • clientHost

      String clientHost()
      Returns:
      the client hostname
    • withDatabaseUser

      RemoteClient withDatabaseUser(User databaseUser)
      Instantiates a new RemoteClient based on this instance but with the specified database user
      Parameters:
      databaseUser - the database user to use
      Returns:
      a new RemoteClient instance
    • copy

      RemoteClient copy()
      Specified by:
      copy in interface ConnectionRequest
      Returns:
      a copy of this remote client with copies of its user instances
    • remoteClient

      static RemoteClient remoteClient(ConnectionRequest connectionRequest)
      Instantiates a new RemoteClient
      Parameters:
      connectionRequest - the connection request
      Returns:
      a new RemoteClient instance
    • remoteClient

      static RemoteClient remoteClient(ConnectionRequest connectionRequest, String clientHost)
      Instantiates a new RemoteClient
      Parameters:
      connectionRequest - the connection request
      clientHost - the client hostname
      Returns:
      a new RemoteClient instance
    • remoteClient

      static RemoteClient remoteClient(ConnectionRequest connectionRequest, User databaseUser)
      Instantiates a new RemoteClient
      Parameters:
      connectionRequest - the connection request
      databaseUser - the user to use when connecting to the underlying database
      Returns:
      a new RemoteClient instance
    • remoteClient

      static RemoteClient remoteClient(ConnectionRequest connectionRequest, User databaseUser, String clientHost)
      Instantiates a new RemoteClient
      Parameters:
      connectionRequest - the connection request
      databaseUser - the user to use when connecting to the underlying database
      clientHost - the client hostname
      Returns:
      a new RemoteClient instance