Package org.onosproject.app
Interface ApplicationStore
-
- All Superinterfaces:
Store<ApplicationEvent,ApplicationStoreDelegate>
- All Known Implementing Classes:
DistributedApplicationStore
public interface ApplicationStore extends Store<ApplicationEvent,ApplicationStoreDelegate>
Service for managing network control applications.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description void
activate(ApplicationId appId)
Mark the application as active.Application
create(InputStream appDescStream)
Creates the application from the specified application descriptor input stream.void
deactivate(ApplicationId appId)
Mark the application as deactivated.Application
getApplication(ApplicationId appId)
Returns the application with the supplied application identifier.default InputStream
getApplicationArchive(ApplicationId appId)
Returns stream that contains the application OAR/JAR file contents.Set<Application>
getApplications()
Returns the set of all installed applications.ApplicationId
getId(String name)
Returns the registered id of the application with the given name.Set<Permission>
getPermissions(ApplicationId appId)
Returns the permissions granted to the applications.ApplicationState
getState(ApplicationId appId)
Returns the current application state.void
remove(ApplicationId appId)
Removes the specified application.void
setPermissions(ApplicationId appId, Set<Permission> permissions)
Updates the permissions granted to the applications.-
Methods inherited from interface org.onosproject.store.Store
hasDelegate, setDelegate, unsetDelegate
-
-
-
-
Method Detail
-
getApplications
Set<Application> getApplications()
Returns the set of all installed applications.- Returns:
- set of installed apps
-
getId
ApplicationId getId(String name)
Returns the registered id of the application with the given name.- Parameters:
name
- application name- Returns:
- registered application id
-
getApplication
Application getApplication(ApplicationId appId)
Returns the application with the supplied application identifier.- Parameters:
appId
- application identifier- Returns:
- application descriptor
-
getState
ApplicationState getState(ApplicationId appId)
Returns the current application state.- Parameters:
appId
- application identifier- Returns:
- application state
-
create
Application create(InputStream appDescStream)
Creates the application from the specified application descriptor input stream.- Parameters:
appDescStream
- application archive input stream- Returns:
- application descriptor
-
remove
void remove(ApplicationId appId)
Removes the specified application.- Parameters:
appId
- application identifier
-
activate
void activate(ApplicationId appId)
Mark the application as active.- Parameters:
appId
- application identifier
-
deactivate
void deactivate(ApplicationId appId)
Mark the application as deactivated.- Parameters:
appId
- application identifier
-
getPermissions
Set<Permission> getPermissions(ApplicationId appId)
Returns the permissions granted to the applications.- Parameters:
appId
- application identifier- Returns:
- set of granted permissions
-
setPermissions
void setPermissions(ApplicationId appId, Set<Permission> permissions)
Updates the permissions granted to the applications.- Parameters:
appId
- application identifierpermissions
- set of granted permissions
-
getApplicationArchive
default InputStream getApplicationArchive(ApplicationId appId)
Returns stream that contains the application OAR/JAR file contents.- Parameters:
appId
- application identifier- Returns:
- input stream containing the app OAR/JAR file
-
-