mirror of
https://github.com/gyurix1968/guacamole-client.git
synced 2025-09-06 13:17:41 +00:00
Provide means for retrieving configuration by identifier.
This commit is contained in:
@@ -50,6 +50,21 @@ import net.sourceforge.guacamole.protocol.GuacamoleConfiguration;
|
|||||||
*/
|
*/
|
||||||
public interface GuacamoleConfigurationDirectory {
|
public interface GuacamoleConfigurationDirectory {
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Returns the GuacamoleConfiguration having the given identifier.
|
||||||
|
*
|
||||||
|
* @param identifier The identifier of the GuacamoleConfiguration to
|
||||||
|
* return.
|
||||||
|
* @return The GuacamoleConfiguration having the given identifier, or null
|
||||||
|
* if no such GuacamoleConfiguration exists.
|
||||||
|
*
|
||||||
|
* @throws GuacamoleException If an error occurs while retrieving the
|
||||||
|
* configuration, or if access to the
|
||||||
|
* configuration is denied.
|
||||||
|
*/
|
||||||
|
GuacamoleConfiguration getConfiguration(String identifier)
|
||||||
|
throws GuacamoleException;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Returns a Map containing all GuacamoleConfigurations. The keys of this
|
* Returns a Map containing all GuacamoleConfigurations. The keys of this
|
||||||
* Map are Strings which uniquely identify each configuration.
|
* Map are Strings which uniquely identify each configuration.
|
||||||
|
@@ -70,6 +70,12 @@ public class SimpleGuacamoleConfigurationDirectory
|
|||||||
this.configs = configs;
|
this.configs = configs;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public GuacamoleConfiguration getConfiguration(String identifier)
|
||||||
|
throws GuacamoleException {
|
||||||
|
return configs.get(identifier);
|
||||||
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public Map<String, GuacamoleConfiguration> getConfigurations()
|
public Map<String, GuacamoleConfiguration> getConfigurations()
|
||||||
throws GuacamoleException {
|
throws GuacamoleException {
|
||||||
|
Reference in New Issue
Block a user