Package org.apache.guacamole.net.auth
Class AbstractActiveConnection
java.lang.Object
org.apache.guacamole.net.auth.AbstractIdentifiable
org.apache.guacamole.net.auth.AbstractActiveConnection
- All Implemented Interfaces:
ActiveConnection
,Connectable
,Identifiable
,Shareable<SharingProfile>
public abstract class AbstractActiveConnection
extends AbstractIdentifiable
implements ActiveConnection
Base implementation of an ActiveConnection, providing storage and simply
getters/setters for its main properties.
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionReturns the identifier of the connection being actively used.Returns the hostname or IP address of the remote host that initiated the connection, if known.Returns the identifier of the sharing profile being actively used.Returns the date and time the connection began.org.apache.guacamole.net.GuacamoleTunnel
Returns the connected GuacamoleTunnel being used.Returns the name of the user who is using this connection.void
setConnectionIdentifier
(String connnectionIdentifier) Sets the identifier of the connection being actively used.void
setRemoteHost
(String remoteHost) Sets the hostname or IP address of the remote host that initiated the connection.void
setSharingProfileIdentifier
(String sharingProfileIdentifier) Sets the identifier of the sharing profile being actively used.void
setStartDate
(Date startDate) Sets the date and time the connection began.void
setTunnel
(org.apache.guacamole.net.GuacamoleTunnel tunnel) Sets the connected GuacamoleTunnel being used.void
setUsername
(String username) Sets the name of the user who is using this connection.Methods inherited from class org.apache.guacamole.net.auth.AbstractIdentifiable
equals, getIdentifier, hashCode, setIdentifier
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface org.apache.guacamole.net.auth.ActiveConnection
connect, getActiveConnections, isConnectable
Methods inherited from interface org.apache.guacamole.net.auth.Connectable
connect
Methods inherited from interface org.apache.guacamole.net.auth.Identifiable
getIdentifier, setIdentifier
Methods inherited from interface org.apache.guacamole.net.auth.Shareable
getSharingCredentials
-
Constructor Details
-
AbstractActiveConnection
public AbstractActiveConnection()
-
-
Method Details
-
getConnectionIdentifier
Description copied from interface:ActiveConnection
Returns the identifier of the connection being actively used. Unlike the other information stored in this object, the connection identifier must be present and MAY NOT be null.- Specified by:
getConnectionIdentifier
in interfaceActiveConnection
- Returns:
- The identifier of the connection being actively used.
-
setConnectionIdentifier
Description copied from interface:ActiveConnection
Sets the identifier of the connection being actively used.- Specified by:
setConnectionIdentifier
in interfaceActiveConnection
- Parameters:
connnectionIdentifier
- The identifier of the connection being actively used.
-
getSharingProfileIdentifier
Description copied from interface:ActiveConnection
Returns the identifier of the sharing profile being actively used. If the connection is being accessed directly, this will be null.- Specified by:
getSharingProfileIdentifier
in interfaceActiveConnection
- Returns:
- The identifier of the sharing profile being actively used.
-
setSharingProfileIdentifier
Description copied from interface:ActiveConnection
Sets the identifier of the sharing profile being actively used.- Specified by:
setSharingProfileIdentifier
in interfaceActiveConnection
- Parameters:
sharingProfileIdentifier
- The identifier of the sharing profile being actively used.
-
getStartDate
Description copied from interface:ActiveConnection
Returns the date and time the connection began.- Specified by:
getStartDate
in interfaceActiveConnection
- Returns:
- The date and time the connection began, or null if this information is not available.
-
setStartDate
Description copied from interface:ActiveConnection
Sets the date and time the connection began.- Specified by:
setStartDate
in interfaceActiveConnection
- Parameters:
startDate
- The date and time the connection began, or null if this information is not available.
-
getRemoteHost
Description copied from interface:ActiveConnection
Returns the hostname or IP address of the remote host that initiated the connection, if known. If the hostname or IP address is not known, null is returned.- Specified by:
getRemoteHost
in interfaceActiveConnection
- Returns:
- The hostname or IP address of the remote host, or null if this information is not available.
-
setRemoteHost
Description copied from interface:ActiveConnection
Sets the hostname or IP address of the remote host that initiated the connection.- Specified by:
setRemoteHost
in interfaceActiveConnection
- Parameters:
remoteHost
- The hostname or IP address of the remote host, or null if this information is not available.
-
getUsername
Description copied from interface:ActiveConnection
Returns the name of the user who is using this connection.- Specified by:
getUsername
in interfaceActiveConnection
- Returns:
- The name of the user who is using this connection, or null if this information is not available.
-
setUsername
Description copied from interface:ActiveConnection
Sets the name of the user who is using this connection.- Specified by:
setUsername
in interfaceActiveConnection
- Parameters:
username
- The name of the user who is using this connection, or null if this information is not available.
-
getTunnel
public org.apache.guacamole.net.GuacamoleTunnel getTunnel()Description copied from interface:ActiveConnection
Returns the connected GuacamoleTunnel being used. This may be null if access to the underlying tunnel is denied.- Specified by:
getTunnel
in interfaceActiveConnection
- Returns:
- The connected GuacamoleTunnel, or null if permission is denied.
-
setTunnel
public void setTunnel(org.apache.guacamole.net.GuacamoleTunnel tunnel) Description copied from interface:ActiveConnection
Sets the connected GuacamoleTunnel being used.- Specified by:
setTunnel
in interfaceActiveConnection
- Parameters:
tunnel
- The connected GuacamoleTunnel, or null if permission is denied.
-