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 Constructor Description AbstractActiveConnection()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description StringgetConnectionIdentifier()Returns the identifier of the connection being actively used.StringgetRemoteHost()Returns the hostname or IP address of the remote host that initiated the connection, if known.StringgetSharingProfileIdentifier()Returns the identifier of the sharing profile being actively used.DategetStartDate()Returns the date and time the connection began.org.apache.guacamole.net.GuacamoleTunnelgetTunnel()Returns the connected GuacamoleTunnel being used.StringgetUsername()Returns the name of the user who is using this connection.voidsetConnectionIdentifier(String connnectionIdentifier)Sets the identifier of the connection being actively used.voidsetRemoteHost(String remoteHost)Sets the hostname or IP address of the remote host that initiated the connection.voidsetSharingProfileIdentifier(String sharingProfileIdentifier)Sets the identifier of the sharing profile being actively used.voidsetStartDate(Date startDate)Sets the date and time the connection began.voidsetTunnel(org.apache.guacamole.net.GuacamoleTunnel tunnel)Sets the connected GuacamoleTunnel being used.voidsetUsername(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
-
-
-
-
Method Detail
-
getConnectionIdentifier
public String getConnectionIdentifier()
Description copied from interface:ActiveConnectionReturns 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:
getConnectionIdentifierin interfaceActiveConnection- Returns:
- The identifier of the connection being actively used.
-
setConnectionIdentifier
public void setConnectionIdentifier(String connnectionIdentifier)
Description copied from interface:ActiveConnectionSets the identifier of the connection being actively used.- Specified by:
setConnectionIdentifierin interfaceActiveConnection- Parameters:
connnectionIdentifier- The identifier of the connection being actively used.
-
getSharingProfileIdentifier
public String getSharingProfileIdentifier()
Description copied from interface:ActiveConnectionReturns the identifier of the sharing profile being actively used. If the connection is being accessed directly, this will be null.- Specified by:
getSharingProfileIdentifierin interfaceActiveConnection- Returns:
- The identifier of the sharing profile being actively used.
-
setSharingProfileIdentifier
public void setSharingProfileIdentifier(String sharingProfileIdentifier)
Description copied from interface:ActiveConnectionSets the identifier of the sharing profile being actively used.- Specified by:
setSharingProfileIdentifierin interfaceActiveConnection- Parameters:
sharingProfileIdentifier- The identifier of the sharing profile being actively used.
-
getStartDate
public Date getStartDate()
Description copied from interface:ActiveConnectionReturns the date and time the connection began.- Specified by:
getStartDatein interfaceActiveConnection- Returns:
- The date and time the connection began, or null if this information is not available.
-
setStartDate
public void setStartDate(Date startDate)
Description copied from interface:ActiveConnectionSets the date and time the connection began.- Specified by:
setStartDatein interfaceActiveConnection- Parameters:
startDate- The date and time the connection began, or null if this information is not available.
-
getRemoteHost
public String getRemoteHost()
Description copied from interface:ActiveConnectionReturns 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:
getRemoteHostin interfaceActiveConnection- Returns:
- The hostname or IP address of the remote host, or null if this information is not available.
-
setRemoteHost
public void setRemoteHost(String remoteHost)
Description copied from interface:ActiveConnectionSets the hostname or IP address of the remote host that initiated the connection.- Specified by:
setRemoteHostin interfaceActiveConnection- Parameters:
remoteHost- The hostname or IP address of the remote host, or null if this information is not available.
-
getUsername
public String getUsername()
Description copied from interface:ActiveConnectionReturns the name of the user who is using this connection.- Specified by:
getUsernamein interfaceActiveConnection- Returns:
- The name of the user who is using this connection, or null if this information is not available.
-
setUsername
public void setUsername(String username)
Description copied from interface:ActiveConnectionSets the name of the user who is using this connection.- Specified by:
setUsernamein 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:ActiveConnectionReturns the connected GuacamoleTunnel being used. This may be null if access to the underlying tunnel is denied.- Specified by:
getTunnelin 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:ActiveConnectionSets the connected GuacamoleTunnel being used.- Specified by:
setTunnelin interfaceActiveConnection- Parameters:
tunnel- The connected GuacamoleTunnel, or null if permission is denied.
-
-