public class DefaultAppRepository extends Object implements AppRepository
| Constructor and Description |
|---|
DefaultAppRepository() |
DefaultAppRepository(org.wso2.carbon.registry.core.Registry registry) |
| Modifier and Type | Method and Description |
|---|---|
int |
addSubscription(String subscriberName,
org.wso2.carbon.appmgt.api.model.WebApp webApp,
String applicationName)
Add user subscription for a webapp/site
|
String |
createNewVersion(org.wso2.carbon.appmgt.api.model.App app)
Creates and persists a new version using the attributes in the given app.
|
org.wso2.carbon.appmgt.api.model.App |
getApp(String type,
String uuid)
Returns the app for the given uuid.
|
String |
getAppUUIDbyName(String appName,
String appVersion,
int tenantId) |
static org.wso2.carbon.governance.api.generic.GenericArtifactManager |
getArtifactManager(org.wso2.carbon.registry.core.Registry registry,
String key) |
org.wso2.carbon.appmgt.api.model.Subscription |
getEnterpriseSubscription(String webAppContext,
String webAppVersion) |
org.wso2.carbon.appmgt.api.model.OneTimeDownloadLink |
getOneTimeDownloadLinkDetails(String UUID)
Retrieve one-time download link details from database
|
org.wso2.carbon.appmgt.api.model.FileContent |
getStaticContent(String contentId)
Retrieve the given static content from storage
|
org.wso2.carbon.appmgt.api.model.WebApp |
getWebAppByContextAndVersion(String context,
String version,
int tenantId)
Returns the web app for the give context and the version.
|
org.wso2.carbon.appmgt.api.model.WebApp |
getWebAppByNameAndVersion(String name,
String version,
int tenantId)
Returns the web app for the given name and version.
|
void |
persistOneTimeDownloadLink(org.wso2.carbon.appmgt.api.model.OneTimeDownloadLink oneTimeDownloadLink)
Persist one-tim download link reference in database
|
void |
persistStaticContents(org.wso2.carbon.appmgt.api.model.FileContent fileContent)
Save static content into storage
|
String |
saveApp(org.wso2.carbon.appmgt.api.model.App app)
Persists the given app in the repository.
|
List<org.wso2.carbon.appmgt.api.model.App> |
searchApps(String type,
Map<String,String> searchTerms)
Searches and returns the apps for the given search terms.
|
void |
updateApp(org.wso2.carbon.appmgt.api.model.App app)
Updates the given app.
|
void |
updateOneTimeDownloadLinkStatus(org.wso2.carbon.appmgt.api.model.OneTimeDownloadLink oneTimeDownloadLink)
Update one-time download link details in database
|
public DefaultAppRepository()
public DefaultAppRepository(org.wso2.carbon.registry.core.Registry registry)
public String saveApp(org.wso2.carbon.appmgt.api.model.App app) throws org.wso2.carbon.appmgt.api.AppManagementException
AppRepositorysaveApp in interface AppRepositoryorg.wso2.carbon.appmgt.api.AppManagementExceptionpublic String createNewVersion(org.wso2.carbon.appmgt.api.model.App app) throws org.wso2.carbon.appmgt.api.AppManagementException
AppRepositorycreateNewVersion in interface AppRepositoryorg.wso2.carbon.appmgt.api.AppManagementExceptionpublic void updateApp(org.wso2.carbon.appmgt.api.model.App app)
throws org.wso2.carbon.appmgt.api.AppManagementException
AppRepositoryupdateApp in interface AppRepositoryorg.wso2.carbon.appmgt.api.AppManagementExceptionpublic org.wso2.carbon.appmgt.api.model.App getApp(String type, String uuid) throws org.wso2.carbon.appmgt.api.AppManagementException
AppRepositorygetApp in interface AppRepositoryorg.wso2.carbon.appmgt.api.AppManagementExceptionpublic org.wso2.carbon.appmgt.api.model.WebApp getWebAppByNameAndVersion(String name, String version, int tenantId) throws org.wso2.carbon.appmgt.api.AppManagementException
AppRepositorygetWebAppByNameAndVersion in interface AppRepositoryorg.wso2.carbon.appmgt.api.AppManagementExceptionpublic org.wso2.carbon.appmgt.api.model.WebApp getWebAppByContextAndVersion(String context, String version, int tenantId) throws org.wso2.carbon.appmgt.api.AppManagementException
AppRepositorygetWebAppByContextAndVersion in interface AppRepositoryorg.wso2.carbon.appmgt.api.AppManagementExceptionpublic List<org.wso2.carbon.appmgt.api.model.App> searchApps(String type, Map<String,String> searchTerms) throws org.wso2.carbon.appmgt.api.AppManagementException
AppRepositorysearchApps in interface AppRepositoryorg.wso2.carbon.appmgt.api.AppManagementExceptionpublic void persistStaticContents(org.wso2.carbon.appmgt.api.model.FileContent fileContent)
throws org.wso2.carbon.appmgt.api.AppManagementException
AppRepositorypersistStaticContents in interface AppRepositoryfileContent - details of file contentorg.wso2.carbon.appmgt.api.AppManagementExceptionpublic org.wso2.carbon.appmgt.api.model.FileContent getStaticContent(String contentId) throws org.wso2.carbon.appmgt.api.AppManagementException
AppRepositorygetStaticContent in interface AppRepositorycontentId - static content uuidorg.wso2.carbon.appmgt.api.AppManagementExceptionpublic int addSubscription(String subscriberName, org.wso2.carbon.appmgt.api.model.WebApp webApp, String applicationName) throws org.wso2.carbon.appmgt.api.AppManagementException
AppRepositoryaddSubscription in interface AppRepositorysubscriberName - Subscriber usernamewebApp - WebApp objectapplicationName - Application Nameorg.wso2.carbon.appmgt.api.AppManagementExceptionpublic void persistOneTimeDownloadLink(org.wso2.carbon.appmgt.api.model.OneTimeDownloadLink oneTimeDownloadLink)
throws org.wso2.carbon.appmgt.api.AppManagementException
persistOneTimeDownloadLink in interface AppRepositoryoneTimeDownloadLink - org.wso2.carbon.appmgt.api.AppManagementExceptionpublic String getAppUUIDbyName(String appName, String appVersion, int tenantId) throws org.wso2.carbon.appmgt.api.AppManagementException
getAppUUIDbyName in interface AppRepositoryorg.wso2.carbon.appmgt.api.AppManagementExceptionpublic org.wso2.carbon.appmgt.api.model.OneTimeDownloadLink getOneTimeDownloadLinkDetails(String UUID) throws org.wso2.carbon.appmgt.api.AppManagementException
getOneTimeDownloadLinkDetails in interface AppRepositoryUUID - org.wso2.carbon.appmgt.api.AppManagementExceptionpublic void updateOneTimeDownloadLinkStatus(org.wso2.carbon.appmgt.api.model.OneTimeDownloadLink oneTimeDownloadLink)
throws org.wso2.carbon.appmgt.api.AppManagementException
AppRepositoryupdateOneTimeDownloadLinkStatus in interface AppRepositoryoneTimeDownloadLink - OneTimeDownloadLink contentorg.wso2.carbon.appmgt.api.AppManagementExceptionpublic org.wso2.carbon.appmgt.api.model.Subscription getEnterpriseSubscription(String webAppContext, String webAppVersion) throws org.wso2.carbon.appmgt.api.AppManagementException
getEnterpriseSubscription in interface AppRepositoryorg.wso2.carbon.appmgt.api.AppManagementExceptionpublic static org.wso2.carbon.governance.api.generic.GenericArtifactManager getArtifactManager(org.wso2.carbon.registry.core.Registry registry,
String key)
throws org.wso2.carbon.registry.core.exceptions.RegistryException
org.wso2.carbon.registry.core.exceptions.RegistryExceptionCopyright © 2017 WSO2. All rights reserved.