mirror of
https://github.com/gyurix1968/guacamole-client.git
synced 2025-09-06 21:27:40 +00:00
GUAC-1132: Modify API to support listing of active connections and host information.
This commit is contained in:
@@ -43,6 +43,11 @@ public class APIConnectionRecord {
|
||||
*/
|
||||
private final Date endDate;
|
||||
|
||||
/**
|
||||
* The host from which the connection originated, if known.
|
||||
*/
|
||||
private final String remoteHost;
|
||||
|
||||
/**
|
||||
* The name of the user who used or is using the connection.
|
||||
*/
|
||||
@@ -61,10 +66,11 @@ public class APIConnectionRecord {
|
||||
* The record to copy data from.
|
||||
*/
|
||||
public APIConnectionRecord(ConnectionRecord record) {
|
||||
this.startDate = record.getStartDate();
|
||||
this.endDate = record.getEndDate();
|
||||
this.username = record.getUsername();
|
||||
this.active = record.isActive();
|
||||
this.startDate = record.getStartDate();
|
||||
this.endDate = record.getEndDate();
|
||||
this.remoteHost = record.getRemoteHost();
|
||||
this.username = record.getUsername();
|
||||
this.active = record.isActive();
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -88,6 +94,16 @@ public class APIConnectionRecord {
|
||||
return endDate;
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns the remote host from which this connection originated.
|
||||
*
|
||||
* @return
|
||||
* The remote host from which this connection originated.
|
||||
*/
|
||||
public String getRemoteHost() {
|
||||
return remoteHost;
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns the name of the user who used or is using the connection at the
|
||||
* times given by this connection record.
|
||||
|
@@ -60,6 +60,13 @@ angular.module('rest').factory('ConnectionHistoryEntry', [function defineConnect
|
||||
*/
|
||||
this.endDate = template.endDate;
|
||||
|
||||
/**
|
||||
* The remote host that initiated this connection, if known.
|
||||
*
|
||||
* @type String
|
||||
*/
|
||||
this.remoteHost = template.remoteHost;
|
||||
|
||||
/**
|
||||
* The username of the user associated with this particular usage of
|
||||
* the connection.
|
||||
|
Reference in New Issue
Block a user