public class PluginsCollection extends java.lang.Object implements RestCollection<TopLevelResource,PluginResource>, AcceptsCreate<TopLevelResource>
| Modifier and Type | Method and Description |
|---|---|
InstallPlugin |
create(TopLevelResource parent,
IdString id)
Handle creation of a child resource.
|
RestView<TopLevelResource> |
list()
Create a view to list the contents of the collection.
|
PluginResource |
parse(java.lang.String id) |
PluginResource |
parse(TopLevelResource parent,
IdString id)
Parse a path component into a resource handle.
|
DynamicMap<RestView<PluginResource>> |
views()
Get the views that support this collection.
|
public RestView<TopLevelResource> list() throws ResourceNotFoundException
RestCollectionThe returned view should accept the parent type to scope the search, and may want to take a "q" parameter option to narrow the results.
list in interface RestCollection<TopLevelResource,PluginResource>ResourceNotFoundException - if the collection cannot be listed.public PluginResource parse(TopLevelResource parent, IdString id) throws ResourceNotFoundException
RestCollectionparse in interface RestCollection<TopLevelResource,PluginResource>parent - the handle to the collection.id - string identifier supplied by the client. In a URL such as /changes/1234/abandon this string is "1234".ResourceNotFoundException - the object does not exist, or the caller is not permitted to
know if the resource exists.public PluginResource parse(java.lang.String id) throws ResourceNotFoundException
ResourceNotFoundExceptionpublic InstallPlugin create(TopLevelResource parent, IdString id) throws ResourceNotFoundException, MethodNotAllowedException
AcceptsCreatecreate in interface AcceptsCreate<TopLevelResource>parent - parent collection handle.id - id of the resource being created.ResourceNotFoundExceptionMethodNotAllowedExceptionpublic DynamicMap<RestView<PluginResource>> views()
RestCollectionWithin a resource the views are accessed as RESOURCE/plugin~view.
views in interface RestCollection<TopLevelResource,PluginResource>