public class Extension extends Object
Constructor and Description |
---|
Extension(ClassLoader parent,
File file)
Loads the given file as an extension, which must be a .jar containing
a guac-manifest.json file describing its contents.
|
Modifier and Type | Method and Description |
---|---|
Collection<Class<AuthenticationProvider>> |
getAuthenticationProviderClasses()
Returns all declared authentication providers classes associated with
this extension.
|
Map<String,Resource> |
getCSSResources()
Returns a map of all declared CSS resources associated with this
extension, where the key of each entry in the map is the path to that
resource within the extension .jar.
|
String |
getGuacamoleVersion()
Returns the version of the Guacamole web application for which this
extension was built.
|
Map<String,Resource> |
getJavaScriptResources()
Returns a map of all declared JavaScript resources associated with this
extension, where the key of each entry in the map is the path to that
resource within the extension .jar.
|
Resource |
getLargeIcon()
Returns the resource for the large favicon for the extension.
|
String |
getName()
Returns the name of this extension, as declared in the extension's
manifest.
|
String |
getNamespace()
Returns the namespace of this extension, as declared in the extension's
manifest.
|
Resource |
getSmallIcon()
Returns the resource for the small favicon for the extension.
|
Map<String,Resource> |
getStaticResources()
Returns a map of all declared resources associated with this extension,
where these resources are not already associated as JavaScript, CSS, or
translation resources.
|
Map<String,Resource> |
getTranslationResources()
Returns a map of all declared translation resources associated with this
extension, where the key of each entry in the map is the path to that
resource within the extension .jar.
|
public Extension(ClassLoader parent, File file) throws GuacamoleException
parent
- The classloader to use as the parent for the isolated classloader of
this extension.file
- The file to load as an extension.GuacamoleException
- If the provided file is not a .jar file, does not contain the
guac-manifest.json, or if guac-manifest.json is invalid and cannot
be parsed.public String getGuacamoleVersion()
public String getName()
public String getNamespace()
public Map<String,Resource> getJavaScriptResources()
public Map<String,Resource> getCSSResources()
public Map<String,Resource> getTranslationResources()
public Map<String,Resource> getStaticResources()
public Collection<Class<AuthenticationProvider>> getAuthenticationProviderClasses()
public Resource getSmallIcon()
public Resource getLargeIcon()
Copyright © 2015. All rights reserved.