/base/location/frameworks/base_module/source/ |
H A D | location.cpp | 16 #include "location.h" 51 Location::Location(Location& location) in Location() argument 53 latitude_ = location.GetLatitude(); in Location() 54 longitude_ = location.GetLongitude(); in Location() 55 altitude_ = location.GetAltitude(); in Location() 56 accuracy_ = location.GetAccuracy(); in Location() 57 speed_ = location.GetSpeed(); in Location() 58 direction_ = location.GetDirection(); in Location() 59 timeStamp_ = location.GetTimeStamp(); in Location() 60 timeSinceBoot_ = location in Location() 119 std::shared_ptr<Location> location = std::make_shared<Location>(); UnmarshallingShared() local 126 std::unique_ptr<Location> location = std::make_unique<Location>(); Unmarshalling() local 187 LocationEqual(const std::unique_ptr<Location>& location) LocationEqual() argument 208 AdditionEqual(const std::unique_ptr<Location>& location) AdditionEqual() argument [all...] |
/base/location/frameworks/native/location_ndk/source/ |
H A D | location_info_callback_host.cpp | 21 #include "location.h" 40 std::unique_ptr<Location> location = Location::Unmarshalling(data); in OnRemoteRequest() local 41 OnLocationReport(location); in OnRemoteRequest() 52 void LocationInfoCallbackHost::OnLocationReport(const std::unique_ptr<Location>& location) in OnLocationReport() argument 57 location_info.latitude = location->GetLatitude(); in OnLocationReport() 58 location_info.longitude = location->GetLongitude(); in OnLocationReport() 59 location_info.altitude = location->GetAltitude(); in OnLocationReport() 60 location_info.accuracy = location->GetAccuracy(); in OnLocationReport() 61 location_info.speed = location->GetSpeed(); in OnLocationReport() 62 location_info.direction = location in OnLocationReport() [all...] |
H A D | locator_c_impl.cpp | 104 Location_BasicInfo OH_LocationInfo_GetBasicInfo(Location_Info* location) in OH_LocationInfo_GetBasicInfo() argument 108 if (location == nullptr) { in OH_LocationInfo_GetBasicInfo() 111 location_Basic.latitude = location->latitude; in OH_LocationInfo_GetBasicInfo() 112 location_Basic.longitude = location->longitude; in OH_LocationInfo_GetBasicInfo() 113 location_Basic.altitude = location->altitude; in OH_LocationInfo_GetBasicInfo() 114 location_Basic.accuracy = location->accuracy; in OH_LocationInfo_GetBasicInfo() 115 location_Basic.speed = location->speed; in OH_LocationInfo_GetBasicInfo() 116 location_Basic.direction = location->direction; in OH_LocationInfo_GetBasicInfo() 117 location_Basic.timeForFix = location->timeForFix; in OH_LocationInfo_GetBasicInfo() 118 location_Basic.timeSinceBoot = location in OH_LocationInfo_GetBasicInfo() 127 OH_LocationInfo_GetAdditionalInfo(Location_Info* location, char* additionalInfo, uint32_t length) OH_LocationInfo_GetAdditionalInfo() argument [all...] |
/base/location/services/location_locator/locator/source/ |
H A D | fusion_controller.cpp | 64 std::unique_ptr<Location> FusionController::chooseBestLocation(const std::unique_ptr<Location>& location, in chooseBestLocation() argument 67 if (location == nullptr) { in chooseBestLocation() 71 return std::make_unique<Location>(*location); in chooseBestLocation() 73 if (location->GetLocationSourceType() == LocationSourceType::INDOOR_TYPE) { in chooseBestLocation() 74 if (CheckIfLastGnssLocationValid(location, std::make_unique<Location>(*lastFuseLocation)) && in chooseBestLocation() 78 return std::make_unique<Location>(*location); in chooseBestLocation() 79 } else if (location->GetLocationSourceType() == LocationSourceType::GNSS_TYPE || in chooseBestLocation() 80 location->GetLocationSourceType() == LocationSourceType::RTK_TYPE) { in chooseBestLocation() 81 if (location->GetSpeed() >= MAX_INDOOR_LOCATION_SPEED) { in chooseBestLocation() 82 return std::make_unique<Location>(*location); in chooseBestLocation() 97 CheckIfLastIndoorLocationValid(const std::unique_ptr<Location>& location, const std::unique_ptr<Location>& lastFuseLocation) CheckIfLastIndoorLocationValid() argument 109 CheckIfLastGnssLocationValid(const std::unique_ptr<Location>& location, const std::unique_ptr<Location>& lastFuseLocation) CheckIfLastGnssLocationValid() argument 121 GetFuseLocation(const std::unique_ptr<Location>& location, const sptr<Location>& lastFuseLocation) GetFuseLocation() argument [all...] |
H A D | report_manager.cpp | 56 bool ReportManager::OnReportLocation(const std::unique_ptr<Location>& location, std::string abilityName) in OnReportLocation() argument 59 UpdateCacheLocation(location, abilityName); in OnReportLocation() 73 WriteNetWorkReportEvent(abilityName, request, location); in OnReportLocation() 75 if (request->GetUuid() == location->GetUuid() || location->GetIsFromMock()) { in OnReportLocation() 76 ProcessRequestForReport(request, deadRequests, location, abilityName); in OnReportLocation() 80 ProcessRequestForReport(request, deadRequests, location, abilityName); in OnReportLocation() 101 std::unique_ptr<Location>& location) in UpdateLocationByRequest() 103 if (location == nullptr) { in UpdateLocationByRequest() 107 location in UpdateLocationByRequest() 100 UpdateLocationByRequest(const uint32_t tokenId, const uint64_t tokenIdEx, std::unique_ptr<Location>& location) UpdateLocationByRequest() argument 113 ProcessRequestForReport(std::shared_ptr<Request>& request, std::unique_ptr<std::list<std::shared_ptr<Request>>>& deadRequests, const std::unique_ptr<Location>& location, std::string abilityName) ProcessRequestForReport() argument 169 ExecuteReportProcess(std::shared_ptr<Request>& request, std::unique_ptr<Location>& location, std::string abilityName) ExecuteReportProcess() argument 185 GetPermittedLocation(const std::shared_ptr<Request>& request, const std::unique_ptr<Location>& location) GetPermittedLocation() argument 250 ResultCheck(const std::unique_ptr<Location>& location, const std::shared_ptr<Request>& request) ResultCheck() argument 300 UpdateCacheLocation(const std::unique_ptr<Location>& location, std::string abilityName) UpdateCacheLocation() argument 316 UpdateLastLocation(const std::unique_ptr<Location>& location) UpdateLastLocation() argument 388 ApproximatelyLocation(const std::unique_ptr<Location>& location) ApproximatelyLocation() argument 445 WriteNetWorkReportEvent(std::string abilityName, const std::shared_ptr<Request>& request, const std::unique_ptr<Location>& location) WriteNetWorkReportEvent() argument [all...] |
/base/location/frameworks/cj/source/ |
H A D | locator_callback.cpp | 41 auto cFunc = reinterpret_cast<void(*)(CJLocation location)>(callbackId); in LocatorCallback() 42 callback_ = [ lambda = CJLambda::Create(cFunc)](const std::unique_ptr<Location::Location>& location) -> in LocatorCallback() 43 void { lambda(NativeLocationToCJLocation(*location)); }; in LocatorCallback() 67 std::unique_ptr<Location::Location> location = Location::Location::Unmarshalling(data); in OnRemoteRequest() local 68 LocatorCallback::OnLocationReport(location); in OnRemoteRequest() 69 if (location->GetLocationSourceType() == Location::LocationSourceType::NETWORK_TYPE && in OnRemoteRequest() 70 location->GetAdditionsMap()["inHdArea"] != "") { in OnRemoteRequest() 71 inHdArea_ = (location->GetAdditionsMap()["inHdArea"] == "true"); in OnRemoteRequest() 73 if (NeedSetSingleLocation(location)) { in OnRemoteRequest() 74 SetSingleLocation(location); in OnRemoteRequest() 107 OnLocationReport(const std::unique_ptr<Location::Location>& location) OnLocationReport() argument 157 NeedSetSingleLocation(const std::unique_ptr<Location::Location>& location) NeedSetSingleLocation() argument 180 SetSingleLocation(const std::unique_ptr<Location::Location>& location) SetSingleLocation() argument [all...] |
/base/location/test/location_locator/source/ |
H A D | report_manager_test.cpp | 24 #include "location.h" 76 std::unique_ptr<Location> location = std::make_unique<Location>(); in MockLocation() local 89 location->ReadFromParcel(parcel); in MockLocation() 90 return location; in MockLocation() 98 std::unique_ptr<Location> location = std::make_unique<Location>(); in HWTEST_F() local 123 auto location = MockLocation(); in HWTEST_F() local 125 EXPECT_EQ(true, reportManager_->ResultCheck(location, request)); in HWTEST_F() 126 EXPECT_EQ(false, reportManager_->ResultCheck(nullptr, request)); // no location in HWTEST_F() 127 EXPECT_EQ(false, reportManager_->ResultCheck(location, nullptr)); // no request in HWTEST_F() 128 EXPECT_EQ(false, reportManager_->ResultCheck(nullptr, nullptr)); // no location in HWTEST_F() 181 auto location = MockLocation(); HWTEST_F() local 212 std::unique_ptr<Location> location = std::make_unique<Location>(); HWTEST_F() local 248 std::unique_ptr<Location> location = std::make_unique<Location>(); HWTEST_F() local 277 std::unique_ptr<Location> location = std::make_unique<Location>(); HWTEST_F() local 324 std::unique_ptr<Location> location = std::make_unique<Location>(); HWTEST_F() local 347 std::unique_ptr<Location> location = std::make_unique<Location>(); HWTEST_F() local 372 std::unique_ptr<Location> location = std::make_unique<Location>(); HWTEST_F() local 436 auto location = MockLocation(); HWTEST_F() local 446 std::unique_ptr<Location> location = nullptr; HWTEST_F() local 470 std::unique_ptr<Location> location = std::make_unique<Location>(); HWTEST_F() local 490 std::unique_ptr<Location> location = std::make_unique<Location>(); HWTEST_F() local 511 std::unique_ptr<Location> location = std::make_unique<Location>(); HWTEST_F() local [all...] |
H A D | fusion_controller_test.cpp | 115 std::unique_ptr<Location> location = std::make_unique<Location>(); in HWTEST_F() local 116 location->ReadFromParcel(parcel); in HWTEST_F() 117 EXPECT_EQ(nullptr, fusionController_->chooseBestLocation(nullptr, location)); in HWTEST_F() 166 std::unique_ptr<Location> location = std::make_unique<Location>(); in HWTEST_F() local 168 location->SetLocationSourceType(LocationSourceType::INDOOR_TYPE); in HWTEST_F() 169 EXPECT_NE(nullptr, fusionController_->GetFuseLocation(location, lastFuseLocation)); in HWTEST_F() 178 std::unique_ptr<Location> location = std::make_unique<Location>(); in HWTEST_F() local 180 location->SetLocationSourceType(LocationSourceType::GNSS_TYPE); in HWTEST_F() 183 location->SetTimeSinceBoot(seconds1 * MILLI_PER_SECS * NANOS_PER_MILLI); in HWTEST_F() 186 EXPECT_NE(nullptr, fusionController_->GetFuseLocation(location, lastFuseLocatio in HWTEST_F() 195 std::unique_ptr<Location> location = std::make_unique<Location>(); HWTEST_F() local [all...] |
H A D | location_approximately_permission_test.cpp | 25 #include "location.h" 82 std::unique_ptr<Location> location = std::make_unique<Location>(); in HWTEST_F() local 83 location->ReadFromParcel(parcel); in HWTEST_F() 84 auto newLocation = reportManager_->GetPermittedLocation(request, location); in HWTEST_F() 109 std::unique_ptr<Location> location = std::make_unique<Location>(); in HWTEST_F() local 110 location->ReadFromParcel(parcel); in HWTEST_F() 111 auto newLocation = reportManager_->GetPermittedLocation(request, location); in HWTEST_F()
|
/base/location/services/location_network/network/source/ |
H A D | network_callback_host.cpp | 39 std::unique_ptr<Location> location = Location::Unmarshalling(data); in OnRemoteRequest() local 40 OnLocationReport(location); in OnRemoteRequest() 44 std::unique_ptr<Location> location = Location::Unmarshalling(data); in OnRemoteRequest() local 45 OnLocationReport(location); in OnRemoteRequest() 63 void NetworkCallbackHost::OnLocationReport(const std::unique_ptr<Location>& location) in OnLocationReport() argument 72 LBSLOGE(NETWORK, "location mock is enabled, do not report network location!"); in OnLocationReport() 75 std::shared_ptr<Location> locationNew = std::make_shared<Location>(*location); in OnLocationReport() 77 WriteLocationInnerEvent(NETWORK_CALLBACK_LOCATION, {"speed", std::to_string(location->GetSpeed()), in OnLocationReport() 78 "accuracy", std::to_string(location in OnLocationReport() [all...] |
/base/location/frameworks/location_common/common/source/ |
H A D | request.cpp | 191 void Request::SetLastLocation(const std::unique_ptr<Location>& location) in SetLastLocation() argument 193 if (lastLocation_ == nullptr || location == nullptr) { in SetLastLocation() 196 lastLocation_->SetLatitude(location->GetLatitude()); in SetLastLocation() 197 lastLocation_->SetLongitude(location->GetLongitude()); in SetLastLocation() 198 lastLocation_->SetAltitude(location->GetAltitude()); in SetLastLocation() 199 lastLocation_->SetAccuracy(location->GetAccuracy()); in SetLastLocation() 200 lastLocation_->SetSpeed(location->GetSpeed()); in SetLastLocation() 201 lastLocation_->SetDirection(location->GetDirection()); in SetLastLocation() 202 lastLocation_->SetTimeStamp(location->GetTimeStamp()); in SetLastLocation() 203 lastLocation_->SetTimeSinceBoot(location in SetLastLocation() 212 SetBestLocation(const std::unique_ptr<Location>& location) SetBestLocation() argument [all...] |
/base/location/services/location_locator/locator/include/ |
H A D | report_manager.h | 25 #include "location.h" 36 bool OnReportLocation(const std::unique_ptr<Location>& location, std::string abilityName); 37 bool ResultCheck(const std::unique_ptr<Location>& location, const std::shared_ptr<Request>& request); 38 void UpdateCacheLocation(const std::unique_ptr<Location>& location, std::string abilityName); 42 const std::unique_ptr<Location>& location); 46 std::unique_ptr<Location>& location); 57 std::unique_ptr<Location> ApproximatelyLocation(const std::unique_ptr<Location>& location); 60 const std::unique_ptr<Location>& location, std::string abilityName); 62 const std::unique_ptr<Location>& location); 64 std::unique_ptr<Location>& location, st [all...] |
H A D | fusion_controller.h | 22 #include "location.h" 33 const std::unique_ptr<Location>& location, const sptr<Location>& lastFuseLocation); 37 bool CheckIfLastIndoorLocationValid(const std::unique_ptr<Location>& location, 39 bool CheckIfLastGnssLocationValid(const std::unique_ptr<Location>& location, 41 bool CheckIfLastRtkLocationValid(const std::unique_ptr<Location>& location,
|
H A D | subability_common.h | 25 #include "location.h" 38 const std::vector<std::shared_ptr<Location>> &location) = 0; 52 bool SetMockedLocations(const int timeInterval, const std::vector<std::shared_ptr<Location>> &location); 58 void ReportLocationInfo(const std::string& systemAbility, const std::shared_ptr<Location> location); 65 void CacheLocationMock(const std::vector<std::shared_ptr<Location>> &location);
|
/base/location/services/location_gnss/gnss/source/ |
H A D | gnss_event_callback.cpp | 55 int32_t GnssEventCallback::ReportLocation(const LocationInfo& location) in ReportLocation() argument 60 locationNew->SetLatitude(location.latitude); in ReportLocation() 61 locationNew->SetLongitude(location.longitude); in ReportLocation() 62 locationNew->SetAltitude(location.altitude); in ReportLocation() 63 locationNew->SetAccuracy(location.horizontalAccuracy); in ReportLocation() 64 locationNew->SetSpeed(location.speed); in ReportLocation() 65 locationNew->SetDirection(location.bearing); in ReportLocation() 66 locationNew->SetAltitudeAccuracy(location.verticalAccuracy); in ReportLocation() 67 locationNew->SetSpeedAccuracy(location.speedAccuracy); in ReportLocation() 68 locationNew->SetDirectionAccuracy(location in ReportLocation() [all...] |
/base/location/frameworks/native/locator_agent/source/ |
H A D | native_location_callback_host.cpp | 21 #include "location.h" 36 std::unique_ptr<Location> location = Location::Unmarshalling(data); in OnRemoteRequest() local 37 OnLocationReport(location); in OnRemoteRequest() 48 void NativeLocationCallbackHost::OnLocationReport(const std::unique_ptr<Location>& location) in OnLocationReport() argument 53 locationCallback.locationUpdate(location); in OnLocationReport()
|
/base/hiviewdfx/faultloggerd/interfaces/innerkits/unwinder/ |
H A D | dfx_instructions.cpp | 43 uintptr_t location; in Flush() local 49 location = cfa + static_cast<uintptr_t>(loc.val); in Flush() 50 memory->ReadUptr(location, &val); in Flush() 53 location = static_cast<uintptr_t>(loc.val); in Flush() 54 if (location >= regs.RegsSize()) { in Flush() 55 DFXLOGE("Illegal register location"); in Flush() 58 val = regs[location]; in Flush() 62 location = dwarfOp.Eval(regs, cfa, loc.val); in Flush() 63 memory->ReadUptr(location, &val); in Flush()
|
/base/telephony/sms_mms/services/sms/gsm/ |
H A D | gsm_user_data_encode.cpp | 57 uint16_t location = buffer.GetIndex(); in EncodeGsmHeadPdu() local 85 if (!buffer.InsertByte((value / HEX_07), location)) { in EncodeGsmHeadPdu() 89 if (!buffer.InsertByte(static_cast<uint8_t>(udhl), location + 1)) { in EncodeGsmHeadPdu() 94 if (!buffer.InsertByte(userData->length, location)) { in EncodeGsmHeadPdu() 132 uint16_t location = buffer.GetIndex(); in Encode8bitHeadPdu() local 151 if (!buffer.InsertByte(static_cast<uint8_t>(udhl + 1 + userData->length), location)) { in Encode8bitHeadPdu() 155 if (!buffer.InsertByte(static_cast<uint8_t>(udhl), location + 1)) { in Encode8bitHeadPdu() 160 if (!buffer.InsertByte(userData->length, location)) { in Encode8bitHeadPdu() 206 uint16_t location = buffer.GetIndex(); in EncodeUcs2HeadPdu() local 226 if (!buffer.InsertByte(static_cast<uint8_t>(udhl + 1 + userData->length), location)) { in EncodeUcs2HeadPdu() [all...] |
/base/web/webview/test/unittest/ohos_adapter/location_callback_adapter_test/ |
H A D | location_callback_adapter_test.cpp | 52 const std::shared_ptr<LocationInfo> location) override 95 std::unique_ptr<OHOS::Location::Location> location = std::make_unique<OHOS::Location::Location>(); in HWTEST_F() local 96 EXPECT_NE(location, nullptr); in HWTEST_F() 97 locationImpl->OnLocationReport(location); in HWTEST_F() 123 std::unique_ptr<OHOS::Location::Location> location = std::make_unique<OHOS::Location::Location>(); in HWTEST_F() local 124 EXPECT_NE(location, nullptr); in HWTEST_F() 125 locationImpl->OnLocationReport(location); in HWTEST_F()
|
/base/location/test/fuzztest/locator/reportmanager_fuzzer/ |
H A D | reportmanager_fuzzer.cpp | 19 #include "location.h" 37 std::unique_ptr<OHOS::Location::Location> location = in ReportManagerFuzzerTest() local 48 reportManager->ResultCheck(location, request); in ReportManagerFuzzerTest() 49 reportManager->UpdateCacheLocation(location, "gps"); in ReportManagerFuzzerTest() 55 reportManager->GetPermittedLocation(request, location); in ReportManagerFuzzerTest()
|
/base/web/webview/ohos_adapter/location_adapter/src/ |
H A D | location_callback_adapter_impl.cpp | 41 std::unique_ptr<OHOS::Location::Location> location = in OnRemoteRequest() local 43 OnLocationReport(location); in OnRemoteRequest() 65 const std::unique_ptr<OHOS::Location::Location>& location) in OnLocationReport() 68 std::make_unique<OHOS::Location::Location>(*location); in OnLocationReport() 64 OnLocationReport( const std::unique_ptr<OHOS::Location::Location>& location) OnLocationReport() argument
|
/base/location/frameworks/native/locator_sdk/source/ |
H A D | locator_callback_host.cpp | 32 std::unique_ptr<Location> location = Location::Unmarshalling(data); in OnRemoteRequest() local 33 OnLocationReport(location); in OnRemoteRequest() 55 void LocatorCallbackHost::OnLocationReport(const std::unique_ptr<Location>& location) in OnLocationReport() argument
|
/base/location/frameworks/cj/include/ |
H A D | locator_callback.h | 25 #include "location.h" 38 void OnLocationReport(const std::unique_ptr<Location::Location>& location) override; 79 bool NeedSetSingleLocation(const std::unique_ptr<Location::Location>& location); 81 void SetSingleLocation(const std::unique_ptr<Location::Location>& location); 85 std::function<void(const std::unique_ptr<Location::Location>& location)> callback_ = nullptr;
|
/base/update/sys_installer/frameworks/installer_manager/src/ |
H A D | installer_manager.cpp | 79 const std::string &location, const std::string &cfgDir) in StartUpdateParaZip() 85 return helper_->StartUpdateParaZip(pkgPath, location, cfgDir); in StartUpdateParaZip() 88 int32_t InstallerManager::StartDeleteParaZip(const std::string &location, const std::string &cfgDir) in StartDeleteParaZip() argument 94 return helper_->StartDeleteParaZip(location, cfgDir); in StartDeleteParaZip() 78 StartUpdateParaZip(const std::string &pkgPath, const std::string &location, const std::string &cfgDir) StartUpdateParaZip() argument
|
/base/update/sys_installer/frameworks/installer_manager/include/ |
H A D | installer_manager_helper.h | 32 const std::string &location, const std::string &cfgDir) = 0; 33 virtual int32_t StartDeleteParaZip(const std::string &location, const std::string &cfgDir) = 0; 49 const std::string &location, const std::string &cfgDir); 50 virtual int32_t StartDeleteParaZip(const std::string &location, const std::string &cfgDir);
|