Interface ExternalGadgetStore
- All Known Implementing Classes:
CachingExternalGadgetStore
,OfbizExternalGadgetStore
public interface ExternalGadgetStore
Provides storage mechanism for gadgets whitelisted by an admin in JIRA.
- Since:
- v4.0
-
Method Summary
Modifier and TypeMethodDescriptioncom.atlassian.gadgets.directory.spi.ExternalGadgetSpec
addGadgetSpecUri
(URI uri) Adds the URI specified to the whitelist.boolean
containsSpecUri
(URI uri) Checks if the specified URI is already contained in the storeSet<com.atlassian.gadgets.directory.spi.ExternalGadgetSpec>
Retrieves a set of all external gadgets whitelisted in the directory.void
removeGadgetSpecUri
(com.atlassian.gadgets.directory.spi.ExternalGadgetSpecId id) Removes the URI specified from the whitelist.
-
Method Details
-
getAllGadgetSpecUris
Set<com.atlassian.gadgets.directory.spi.ExternalGadgetSpec> getAllGadgetSpecUris()Retrieves a set of all external gadgets whitelisted in the directory.- Returns:
- a set of all external gadgets whitelisted in the directory.
-
addGadgetSpecUri
Adds the URI specified to the whitelist.- Parameters:
uri
- The gadget URI to add- Returns:
- The newly created ExternalGAdgetSpec
- Throws:
IllegalStateException
- if the store already contains the uri specified
-
removeGadgetSpecUri
void removeGadgetSpecUri(com.atlassian.gadgets.directory.spi.ExternalGadgetSpecId id) Removes the URI specified from the whitelist.- Parameters:
id
- The id to remove
-
containsSpecUri
Checks if the specified URI is already contained in the store- Parameters:
uri
- the URI to check for- Returns:
- true if the URI already exists in the store
-