mirror of
https://github.com/gyurix1968/guacamole-client.git
synced 2025-09-06 05:07:41 +00:00
GUAC-1170: Use checked versions of empty list/set/map.
This commit is contained in:
@@ -65,7 +65,7 @@ public class CredentialsInfo {
|
||||
* CredentialsInfo object which describes empty credentials. No parameters
|
||||
* are required.
|
||||
*/
|
||||
public static final CredentialsInfo EMPTY = new CredentialsInfo(Collections.EMPTY_LIST);
|
||||
public static final CredentialsInfo EMPTY = new CredentialsInfo(Collections.<Parameter>emptyList());
|
||||
|
||||
/**
|
||||
* CredentialsInfo object which describes standard username/password
|
||||
|
@@ -117,7 +117,7 @@ public class SimpleConnection extends AbstractConnection {
|
||||
|
||||
@Override
|
||||
public List<ConnectionRecord> getHistory() throws GuacamoleException {
|
||||
return Collections.EMPTY_LIST;
|
||||
return Collections.<ConnectionRecord>emptyList();
|
||||
}
|
||||
|
||||
}
|
||||
|
@@ -45,7 +45,7 @@ public class SimpleDirectory<ObjectType> implements Directory<ObjectType> {
|
||||
/**
|
||||
* The Map of objects to provide access to.
|
||||
*/
|
||||
private Map<String, ObjectType> objects = Collections.EMPTY_MAP;
|
||||
private Map<String, ObjectType> objects = Collections.<String, ObjectType>emptyMap();
|
||||
|
||||
/**
|
||||
* Creates a new empty SimpleDirectory which does not provide access to
|
||||
|
@@ -42,7 +42,7 @@ public class SimpleObjectPermissionSet implements ObjectPermissionSet {
|
||||
/**
|
||||
* The set of all permissions currently granted.
|
||||
*/
|
||||
private Set<ObjectPermission> permissions = Collections.EMPTY_SET;
|
||||
private Set<ObjectPermission> permissions = Collections.<ObjectPermission>emptySet();
|
||||
|
||||
/**
|
||||
* Creates a new empty SimpleObjectPermissionSet.
|
||||
|
@@ -40,7 +40,7 @@ public class SimpleSystemPermissionSet implements SystemPermissionSet {
|
||||
/**
|
||||
* The set of all permissions currently granted.
|
||||
*/
|
||||
private Set<SystemPermission> permissions = Collections.EMPTY_SET;
|
||||
private Set<SystemPermission> permissions = Collections.<SystemPermission>emptySet();
|
||||
|
||||
/**
|
||||
* Creates a new empty SimpleSystemPermissionSet.
|
||||
|
@@ -126,7 +126,7 @@ public class SimpleUserContext implements UserContext {
|
||||
// Add root group that contains only the given configurations
|
||||
this.rootGroup = new SimpleConnectionGroup(
|
||||
ROOT_IDENTIFIER, ROOT_IDENTIFIER,
|
||||
connectionIdentifiers, Collections.EMPTY_LIST
|
||||
connectionIdentifiers, Collections.<String>emptyList()
|
||||
);
|
||||
|
||||
// Build new user from credentials
|
||||
|
Reference in New Issue
Block a user