Package org.apache.guacamole.net.auth
Class DelegatingActivityRecord
- java.lang.Object
-
- org.apache.guacamole.net.auth.DelegatingActivityRecord
-
- All Implemented Interfaces:
ActivityRecord,ReadableAttributes
- Direct Known Subclasses:
DelegatingConnectionRecord
public class DelegatingActivityRecord extends Object implements ActivityRecord
ActivityRecord implementation which simply delegates all function calls to an underlying ActivityRecord.
-
-
Constructor Summary
Constructors Constructor Description DelegatingActivityRecord(ActivityRecord record)Wraps the given ActivityRecord such that all function calls against this DelegatingActivityRecord will be delegated to it.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description Map<String,String>getAttributes()Returns all attributes associated with this object.protected ActivityRecordgetDelegateActivityRecord()Returns the underlying ActivityRecord wrapped by this DelegatingActivityRecord.DategetEndDate()Returns the date and time the activity ended, if applicable.StringgetIdentifier()Returns the unique identifier assigned to this record, if any.Map<String,ActivityLog>getLogs()Returns a Map of logs related to this record and accessible by the current user, such as Guacamole session recordings.StringgetRemoteHost()Returns the hostname or IP address of the remote host that performed the activity associated with this record, if known.DategetStartDate()Returns the date and time the activity began.StringgetUsername()Returns the name of the user who performed or is performing the activity at the times given by this record.UUIDgetUUID()Returns a UUID that uniquely identifies this record.booleanisActive()Returns whether the activity associated with this record is still ongoing.
-
-
-
Constructor Detail
-
DelegatingActivityRecord
public DelegatingActivityRecord(ActivityRecord record)
Wraps the given ActivityRecord such that all function calls against this DelegatingActivityRecord will be delegated to it.- Parameters:
record- The record to wrap.
-
-
Method Detail
-
getDelegateActivityRecord
protected ActivityRecord getDelegateActivityRecord()
Returns the underlying ActivityRecord wrapped by this DelegatingActivityRecord.- Returns:
- The ActivityRecord wrapped by this DelegatingActivityRecord.
-
getStartDate
public Date getStartDate()
Description copied from interface:ActivityRecordReturns the date and time the activity began.- Specified by:
getStartDatein interfaceActivityRecord- Returns:
- The date and time the activity began.
-
getEndDate
public Date getEndDate()
Description copied from interface:ActivityRecordReturns the date and time the activity ended, if applicable.- Specified by:
getEndDatein interfaceActivityRecord- Returns:
- The date and time the activity ended, or null if the activity is still ongoing or if the end time is unknown.
-
getRemoteHost
public String getRemoteHost()
Description copied from interface:ActivityRecordReturns the hostname or IP address of the remote host that performed the activity associated with this record, if known. If the hostname or IP address is not known, null is returned.- Specified by:
getRemoteHostin interfaceActivityRecord- Returns:
- 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:ActivityRecordReturns the name of the user who performed or is performing the activity at the times given by this record.- Specified by:
getUsernamein interfaceActivityRecord- Returns:
- The name of the user who performed or is performing the associated activity.
-
isActive
public boolean isActive()
Description copied from interface:ActivityRecordReturns whether the activity associated with this record is still ongoing.- Specified by:
isActivein interfaceActivityRecord- Returns:
- true if the activity associated with this record is still ongoing, false otherwise.
-
getIdentifier
public String getIdentifier()
Description copied from interface:ActivityRecordReturns the unique identifier assigned to this record, if any. If this record is not uniquely identifiable, this may be null. If provided, this unique identifier MUST be unique across allActivityRecordobjects within the sameActivityRecordSet.- Specified by:
getIdentifierin interfaceActivityRecord- Returns:
- The unique identifier assigned to this record, or null if this record has no such identifier.
-
getUUID
public UUID getUUID()
Description copied from interface:ActivityRecordReturns a UUID that uniquely identifies this record. If provided, this UUID MUST be deterministic and unique across allActivityRecordobjects within the sameActivityRecordSet, and SHOULD be unique across allActivityRecordobjects.- Specified by:
getUUIDin interfaceActivityRecord- Returns:
- A UUID that uniquely identifies this record, or null if no such unique identifier exists.
-
getLogs
public Map<String,ActivityLog> getLogs()
Description copied from interface:ActivityRecordReturns a Map of logs related to this record and accessible by the current user, such as Guacamole session recordings. Each log is associated with a corresponding, arbitrary, unique name. If the user does not have access to any logs, or if no logs are available, this may be an empty map.- Specified by:
getLogsin interfaceActivityRecord- Returns:
- A Map of logs related to this record.
-
getAttributes
public Map<String,String> getAttributes()
Description copied from interface:ReadableAttributesReturns all attributes associated with this object. The returned map may not be modifiable.- Specified by:
getAttributesin interfaceActivityRecord- Specified by:
getAttributesin interfaceReadableAttributes- Returns:
- A map of all attribute identifiers to their corresponding values, for all attributes associated with this object, which may not be modifiable.
-
-