public final class PluginGadgetSpec extends Object
http://<hostname>[:<port>]/[<context>/]<path/to/gadget/location.xml>.
The location of published gadgets returned from getLocation() is a relative path to the gadget spec file
within the plugin.
getLocation() is the absolute URL of the gadget
spec file, beginning with http or https. External gadgets served through protocols other than HTTP
are not supported.| Modifier and Type | Class and Description |
|---|---|
static class |
PluginGadgetSpec.Key
An immutable representation of a unique identifier for plugin gadget specs, composed of a plugin key and resource
location path name.
|
| Constructor and Description |
|---|
PluginGadgetSpec(com.atlassian.plugin.Plugin plugin,
String moduleKey,
String location,
Map<String,String> params)
Deprecated.
Use
builder() instead. |
| Modifier and Type | Method and Description |
|---|---|
static PluginGadgetSpecBuilder |
builder() |
boolean |
equals(Object obj) |
Date |
getDateLoaded() |
com.atlassian.plugin.web.Condition |
getEnabledCondition() |
InputStream |
getInputStream()
Returns the spec resource as an input stream, for processing.
|
PluginGadgetSpec.Key |
getKey()
Returns a unique identifier for this spec.
|
com.atlassian.plugin.web.Condition |
getLocalCondition() |
String |
getLocation()
If
isHostedExternally() returns true, this method returns the absolute URL of the gadget spec file,
beginning with http or https. |
String |
getModuleKey()
Returns the module key for this spec.
|
String |
getParameter(String name) |
String |
getPluginKey()
Returns the plugin key for this spec.
|
String |
getPublishLocation() |
int |
hashCode() |
boolean |
hasParameter(String name) |
boolean |
isHostedExternally()
Returns true if this spec is hosted externally (meaning it is not part of a plugin served by the Gadgets
Publisher plugin), false otherwise.
|
String |
toString() |
public static PluginGadgetSpecBuilder builder()
public com.atlassian.plugin.web.Condition getEnabledCondition()
public com.atlassian.plugin.web.Condition getLocalCondition()
public PluginGadgetSpec.Key getKey()
public String getModuleKey()
public String getPluginKey()
public String getPublishLocation()
public String getLocation()
isHostedExternally() returns true, this method returns the absolute URL of the gadget spec file,
beginning with http or https. If isHostedExternally() returns false, this method returns a relative
location -- the path of the spec file within its plugin.public InputStream getInputStream()
public boolean isHostedExternally()
public boolean hasParameter(String name)
public Date getDateLoaded()
Copyright © 2024 Atlassian. All rights reserved.