mirror of
https://github.com/openharmony/bundlemanager_bundle_framework_lite.git
synced 2026-07-18 17:54:39 -04:00
add
Signed-off-by: shilei <shilei91@huawei.com> Change-Id: Icfff4ccced72857558c9d560c4460f79ed3d63ae
This commit is contained in:
@@ -27,6 +27,7 @@
|
||||
#include "want_utils.h"
|
||||
|
||||
namespace OHOS {
|
||||
const unsigned int BMS_INSTALL_MSG = 100;
|
||||
const unsigned int ERROR_SLEEP_TIMES = 300;
|
||||
const unsigned int RETRY_TIMES = 10;
|
||||
Bmsbuff *g_bmsbuff = nullptr;
|
||||
|
||||
@@ -21,7 +21,6 @@
|
||||
#include "nocopyable.h"
|
||||
|
||||
namespace OHOS {
|
||||
const unsigned int BMS_INSTALL_MSG = 100;
|
||||
const unsigned int BMS_UNINSTALL_MSG = 101;
|
||||
const unsigned int BMS_SCAN_PACKAGE_MSG = 102;
|
||||
const unsigned int BMS_REGISTER_CALLBACK_MSG = 103;
|
||||
|
||||
@@ -40,6 +40,7 @@ public:
|
||||
static bool RegisterInstallerCallback(InstallerCallback installerCallback);
|
||||
static void UpdateBundleInfoList();
|
||||
static uint8_t GetBundleInfosNoReplication(const int flags, BundleInfo **bundleInfos, int32_t *len);
|
||||
static void Init();
|
||||
|
||||
static BundleMgrSliteFeature *GetInstance()
|
||||
{
|
||||
|
||||
@@ -17,6 +17,7 @@
|
||||
|
||||
#include "bundle_service_interface.h"
|
||||
#include "bundlems_log.h"
|
||||
#include "bundle_mgr_slite_feature.h"
|
||||
#include "gt_bundle_manager_service.h"
|
||||
#include "ohos_init.h"
|
||||
#include "samgr_lite.h"
|
||||
@@ -40,6 +41,7 @@ static void Init()
|
||||
CHECK_NULLPTR_RETURN(sm, "BundleManagerService", "get samgr error");
|
||||
#ifdef __LITEOS_M__
|
||||
sm->RegisterService(BundleMgrService::GetInstance());
|
||||
BundleMgrSliteFeature::Init();
|
||||
#else
|
||||
BOOL result = sm->RegisterService(BundleMgrService::GetInstance());
|
||||
PRINTI("BundleManagerService", "bms starts %{public}s", result ? "successfully" : "unsuccessfully");
|
||||
|
||||
@@ -39,7 +39,7 @@ BundleMgrSliteFeatureImpl g_bmsSliteImpl = {
|
||||
DEFAULT_IUNKNOWN_ENTRY_END
|
||||
};
|
||||
|
||||
static void Init()
|
||||
void BundleMgrSliteFeature::Init()
|
||||
{
|
||||
SamgrLite *samgrLite = SAMGR_GetInstance();
|
||||
CHECK_NULLPTR_RETURN(samgrLite, "BundleMgrSliteFeature", "get samgr error");
|
||||
|
||||
Reference in New Issue
Block a user