Home
last modified time | relevance | path

Searched refs:iterator (Results 1 – 25 of 40) sorted by relevance

12

/openthread-3.6.0/src/core/thread/
Dnetwork_data.cpp159 NetworkDataIterator iterator(aIterator); in Iterate() local
162 … cur = iterator.GetTlv(mTlvs), (cur + 1 <= GetTlvsEnd()) && (cur->GetNext() <= GetTlvsEnd()); in Iterate()
163 iterator.AdvanceTlv(mTlvs)) in Iterate()
191 for (const NetworkDataTlv *subCur; subCur = iterator.GetSubTlv(subTlvs), in Iterate()
193 iterator.AdvanceSubTlv(subTlvs)) in Iterate()
210 … for (uint8_t index; (index = iterator.GetAndAdvanceIndex()) < borderRouter->GetNumEntries();) in Iterate()
237 … for (uint8_t index; (index = iterator.GetAndAdvanceIndex()) < hasRoute->GetNumEntries();) in Iterate()
264 if (iterator.IsNewEntry()) in Iterate()
271 iterator.MarkEntryAsNotNew(); in Iterate()
295 if (!iterator.IsNewEntry()) in Iterate()
[all …]
Dnetwork_data_service.cpp111 Iterator iterator; in GetBackboneRouterPrimary() local
113 iterator.mServiceTlv = serviceTlv; in GetBackboneRouterPrimary()
115 while (IterateToNextServer(iterator) == kErrorNone) in GetBackboneRouterPrimary()
120 iterator.mServerSubTlv->GetServerData(data); in GetBackboneRouterPrimary()
130 …IsBackboneRouterPreferredTo(*iterator.mServerSubTlv, *serverData, *rvalServerTlv, *rvalServerData)) in GetBackboneRouterPrimary()
132 rvalServerTlv = iterator.mServerSubTlv; in GetBackboneRouterPrimary()
199 Iterator iterator; in FindPreferredDnsSrpAnycastInfo() local
208 while (GetNextDnsSrpAnycastInfo(iterator, info) == kErrorNone) in FindPreferredDnsSrpAnycastInfo()
235 iterator.Reset(); in FindPreferredDnsSrpAnycastInfo()
237 while (GetNextDnsSrpAnycastInfo(iterator, info) == kErrorNone) in FindPreferredDnsSrpAnycastInfo()
/openthread-3.6.0/src/core/net/
Dnd_agent.cpp52 NetworkData::Iterator iterator; in UpdateService() local
62 iterator = NetworkData::kIteratorInit; in UpdateService()
64 … while (Get<NetworkData::Leader>().GetNextOnMeshPrefix(iterator, rloc16, config) == kErrorNone) in UpdateService()
91 iterator = NetworkData::kIteratorInit; in UpdateService()
93 while (Get<NetworkData::Leader>().GetNextOnMeshPrefix(iterator, rloc16, config) == kErrorNone) in UpdateService()
Ddns_types.cpp183 LabelIterator iterator(*mMessage, mOffset); in AppendTo() local
187 error = iterator.GetNextLabel(); in AppendTo()
192 SuccessOrExit(error = iterator.AppendLabel(aMessage)); in AppendTo()
330 LabelIterator iterator(aMessage, aOffset); in ParseName() local
334 error = iterator.GetNextLabel(); in ParseName()
343 aOffset = iterator.mNameEndOffset; in ParseName()
360 LabelIterator iterator(aMessage, aOffset); in ReadLabel() local
362 SuccessOrExit(error = iterator.GetNextLabel()); in ReadLabel()
363 …SuccessOrExit(error = iterator.ReadLabel(aLabelBuffer, aLabelLength, /* aAllowDotCharInLabel */ tr… in ReadLabel()
364 aOffset = iterator.mNextLabelOffset; in ReadLabel()
[all …]
Ddhcp6_server.cpp66 NetworkData::Iterator iterator; in UpdateService() local
80 iterator = NetworkData::kIteratorInit; in UpdateService()
82 … while (Get<NetworkData::Leader>().GetNextOnMeshPrefix(iterator, rloc16, config) == kErrorNone) in UpdateService()
108 iterator = NetworkData::kIteratorInit; in UpdateService()
110 while (Get<NetworkData::Leader>().GetNextOnMeshPrefix(iterator, rloc16, config) == kErrorNone) in UpdateService()
Ddhcp6_client.cpp72 NetworkData::Iterator iterator; in UpdateAddresses() local
84 iterator = NetworkData::kIteratorInit; in UpdateAddresses()
86 while (Get<NetworkData::Leader>().GetNextOnMeshPrefix(iterator, config) == kErrorNone) in UpdateAddresses()
108 iterator = NetworkData::kIteratorInit; in UpdateAddresses()
110 while (Get<NetworkData::Leader>().GetNextOnMeshPrefix(iterator, config) == kErrorNone) in UpdateAddresses()
/openthread-3.6.0/src/posix/platform/
Dconfiguration.cpp91 int iterator = 0; in GetDomain() local
96 …while (mProductConfigFile.Get(kKeyRegionDomainMapping, iterator, value, sizeof(value)) == OT_ERROR… in GetDomain()
124 int iterator = 0; in GetChannelMask() local
131 while (mProductConfigFile.Get(aKey, iterator, value, sizeof(value)) == OT_ERROR_NONE) in GetChannelMask()
178 int iterator = 0; in UpdateTargetPower() local
183 while (GetNextTargetPower(aDomain, iterator, targetPower) == OT_ERROR_NONE) in UpdateTargetPower()
205 int iterator = 0; in UpdateCalibratedPower() local
213 if (calibrationFile->Get(kKeyCalibratedPower, iterator, value, sizeof(value)) != OT_ERROR_NONE) in UpdateCalibratedPower()
221 iterator = 0; in UpdateCalibratedPower()
222 … while (calibrationFile->Get(kKeyCalibratedPower, iterator, value, sizeof(value)) == OT_ERROR_NONE) in UpdateCalibratedPower()
Dfirewall.cpp86 otNetworkDataIterator iterator = OT_NETWORK_DATA_ITERATOR_INIT; in UpdateIpSets() local
97 while (otNetDataGetNextOnMeshPrefix(aInstance, &iterator, &config) == OT_ERROR_NONE) in UpdateIpSets()
113 iterator = OT_NETWORK_DATA_ITERATOR_INIT; in UpdateIpSets()
114 while (otNetDataGetNextOnMeshPrefix(aInstance, &iterator, &config) == OT_ERROR_NONE) in UpdateIpSets()
Dconfig_file.cpp55 int iterator = 0; in HasKey() local
57 return (Get(aKey, iterator, nullptr, 0) == OT_ERROR_NONE); in HasKey()
/openthread-3.6.0/src/core/api/
Dcoap_api.cpp161 Coap::Option::Iterator &iterator = AsCoreType(aIterator); in otCoapOptionIteratorGetFirstOptionMatching() local
163 IgnoreError(iterator.Init(iterator.GetMessage(), aOption)); in otCoapOptionIteratorGetFirstOptionMatching()
164 return iterator.GetOption(); in otCoapOptionIteratorGetFirstOptionMatching()
169 Coap::Option::Iterator &iterator = AsCoreType(aIterator); in otCoapOptionIteratorGetFirstOption() local
171 IgnoreError(iterator.Init(iterator.GetMessage())); in otCoapOptionIteratorGetFirstOption()
172 return iterator.GetOption(); in otCoapOptionIteratorGetFirstOption()
177 Coap::Option::Iterator &iterator = AsCoreType(aIterator); in otCoapOptionIteratorGetNextOptionMatching() local
179 IgnoreError(iterator.Advance(aOption)); in otCoapOptionIteratorGetNextOptionMatching()
180 return iterator.GetOption(); in otCoapOptionIteratorGetNextOptionMatching()
185 Coap::Option::Iterator &iterator = AsCoreType(aIterator); in otCoapOptionIteratorGetNextOption() local
[all …]
/openthread-3.6.0/src/cli/
Dcli_history.cpp135 otHistoryTrackerIterator iterator; in Process() local
159 otHistoryTrackerInitIterator(&iterator); in Process()
163 info = otHistoryTrackerIterateUnicastAddressHistory(GetInstancePtr(), &iterator, &entryAge); in Process()
251 otHistoryTrackerIterator iterator; in Process() local
279 otHistoryTrackerInitIterator(&iterator); in Process()
283 … info = otHistoryTrackerIterateMulticastAddressHistory(GetInstancePtr(), &iterator, &entryAge); in Process()
366 otHistoryTrackerIterator iterator; in Process() local
394 otHistoryTrackerInitIterator(&iterator); in Process()
398 info = otHistoryTrackerIterateNeighborHistory(GetInstancePtr(), &iterator, &entryAge); in Process()
514 otHistoryTrackerIterator iterator; in Process() local
[all …]
Dcli_mac_filter.cpp46 otMacFilterIterator iterator; in OutputFilter() local
57 iterator = OT_MAC_FILTER_ITERATOR_INIT; in OutputFilter()
59 while (otLinkFilterGetNextAddress(GetInstancePtr(), &iterator, &entry) == OT_ERROR_NONE) in OutputFilter()
72 iterator = OT_MAC_FILTER_ITERATOR_INIT; in OutputFilter()
74 while (otLinkFilterGetNextRssIn(GetInstancePtr(), &iterator, &entry) == OT_ERROR_NONE) in OutputFilter()
Dcli_network_data.cpp569 otNetworkDataIterator iterator = OT_NETWORK_DATA_ITERATOR_INIT; in OutputPrefixes() local
574 while (GetNextPrefix(&iterator, &config, aLocal) == OT_ERROR_NONE) in OutputPrefixes()
602 otNetworkDataIterator iterator = OT_NETWORK_DATA_ITERATOR_INIT; in OutputRoutes() local
607 while (GetNextRoute(&iterator, &config, aLocal) == OT_ERROR_NONE) in OutputRoutes()
635 otNetworkDataIterator iterator = OT_NETWORK_DATA_ITERATOR_INIT; in OutputServices() local
640 while (GetNextService(&iterator, &config, aLocal) == OT_ERROR_NONE) in OutputServices()
648 otNetworkDataIterator iterator = OT_NETWORK_DATA_ITERATOR_INIT; in OutputLowpanContexts() local
655 while (otNetDataGetNextLowpanContextInfo(GetInstancePtr(), &iterator, &info) == OT_ERROR_NONE) in OutputLowpanContexts()
Dcli_br.cpp406 otBorderRoutingPrefixTableIterator iterator; in Process() local
411 otBorderRoutingPrefixTableInitIterator(GetInstancePtr(), &iterator); in Process()
413 …while (otBorderRoutingGetNextPrefixTableEntry(GetInstancePtr(), &iterator, &entry) == OT_ERROR_NON… in Process()
518 otBorderRoutingPrefixTableIterator iterator; in Process() local
523 otBorderRoutingPrefixTableInitIterator(GetInstancePtr(), &iterator); in Process()
525 while (otBorderRoutingGetNextRouterEntry(GetInstancePtr(), &iterator, &entry) == OT_ERROR_NONE) in Process()
Dcli_coap.cpp618 otCoapOptionIterator iterator; in HandleRequest() local
630 SuccessOrExit(error = otCoapOptionIteratorInit(&iterator, aMessage)); in HandleRequest()
633 … if (otCoapOptionIteratorGetFirstOptionMatching(&iterator, OT_COAP_OPTION_OBSERVE) != nullptr) in HandleRequest()
635 SuccessOrExit(error = otCoapOptionIteratorGetOptionUintValue(&iterator, &observe)); in HandleRequest()
643 if (otCoapOptionIteratorGetFirstOptionMatching(&iterator, OT_COAP_OPTION_BLOCK2) != nullptr) in HandleRequest()
645 SuccessOrExit(error = otCoapOptionIteratorGetOptionUintValue(&iterator, &blockValue)); in HandleRequest()
835 otCoapOptionIterator iterator; in HandleResponse() local
842 if (otCoapOptionIteratorInit(&iterator, aMessage) == OT_ERROR_NONE) in HandleResponse()
845 otCoapOptionIteratorGetFirstOptionMatching(&iterator, OT_COAP_OPTION_OBSERVE); in HandleResponse()
850 … otError error = otCoapOptionIteratorGetOptionUintValue(&iterator, &observeVal); in HandleResponse()
Dcli_output.cpp223 otDnsTxtEntryIterator iterator; in OutputDnsTxtData() local
226 otDnsInitTxtEntryIterator(&iterator, aTxtData, aTxtDataLength); in OutputDnsTxtData()
230 while (otDnsGetNextTxtEntry(&iterator, &entry) == OT_ERROR_NONE) in OutputDnsTxtData()
/openthread-3.6.0/src/core/coap/
Dcoap_message.cpp224 Option::Iterator iterator; in ReadUriPathOptions() local
226 SuccessOrExit(error = iterator.Init(*this, kOptionUriPath)); in ReadUriPathOptions()
228 while (!iterator.IsDone()) in ReadUriPathOptions()
230 uint16_t optionLength = iterator.GetOption()->GetLength(); in ReadUriPathOptions()
239 IgnoreError(iterator.ReadOptionValue(curUriPath)); in ReadUriPathOptions()
242 SuccessOrExit(error = iterator.Advance(kOptionUriPath)); in ReadUriPathOptions()
274 Option::Iterator iterator; in ReadBlockOptionValues() local
278 SuccessOrExit(error = iterator.Init(*this, aBlockType)); in ReadBlockOptionValues()
279 SuccessOrExit(error = iterator.ReadOptionValue(buf)); in ReadBlockOptionValues()
284 switch (iterator.GetOption()->GetLength()) in ReadBlockOptionValues()
[all …]
Dcoap.cpp289 Option::Iterator iterator; in SendMessage() local
292 SuccessOrExit(error = iterator.Init(aMessage, kOptionObserve)); in SendMessage()
293 observe = !iterator.IsDone(); in SendMessage()
300 SuccessOrExit(error = iterator.ReadOptionValue(observeVal)); in SendMessage()
624 Option::Iterator iterator; in PrepareNextBlockRequest() local
629 SuccessOrExit(error = iterator.Init(aRequestOld)); in PrepareNextBlockRequest()
632 for (; !iterator.IsDone() && iterator.GetOption()->GetLength() != 0; error = iterator.Advance()) in PrepareNextBlockRequest()
634 uint16_t optionNumber = iterator.GetOption()->GetNumber(); in PrepareNextBlockRequest()
658 SuccessOrExit(error = iterator.ReadOptionValue(&optionBuf)); in PrepareNextBlockRequest()
659 …SuccessOrExit(error = aRequest.AppendOption(optionNumber, iterator.GetOption()->GetLength(), &opti… in PrepareNextBlockRequest()
[all …]
/openthread-3.6.0/tools/ot-fct/
Dcli.cpp98 int iterator = 0; in ProcessTargetPowerTable() local
105 while (GetNextDomain(iterator, domain) == OT_ERROR_NONE) in ProcessTargetPowerTable()
124 int iterator = 0; in ProcessRegionDomainTable() local
131 …while (mProductConfigFile.Get(kKeyRegionDomainMapping, iterator, value, sizeof(value)) == OT_ERROR… in ProcessRegionDomainTable()
188 int iterator = 0; in ProcessCalibrationTable() local
196 …while (mFactoryConfigFile.Get(kKeyCalibratedPower, iterator, value, sizeof(value)) == OT_ERROR_NON… in ProcessCalibrationTable()
238 uint16_t iterator = 0; in ProcessCalibrationTable() local
244 …while (ParseNextCalibratedPower(arg->GetCString(), length, iterator, calibratedPower) == OT_ERROR_… in ProcessCalibrationTable()
/openthread-3.6.0/src/core/utils/
Dslaac_address.cpp163 NetworkData::Iterator iterator; in RemoveAddresses() local
172 iterator = NetworkData::kIteratorInit; in RemoveAddresses()
174 while (Get<NetworkData::Leader>().GetNextOnMeshPrefix(iterator, config) == kErrorNone) in RemoveAddresses()
211 NetworkData::Iterator iterator; in AddAddresses() local
216 iterator = NetworkData::kIteratorInit; in AddAddresses()
218 while (Get<NetworkData::Leader>().GetNextOnMeshPrefix(iterator, config) == kErrorNone) in AddAddresses()
Dhistory_tracker.cpp359 NetworkData::Iterator iterator; in RecordNetworkDataChange() local
365 iterator = NetworkData::kIteratorInit; in RecordNetworkDataChange()
367 while (mPreviousNetworkData.GetNextOnMeshPrefix(iterator, prefix) == kErrorNone) in RecordNetworkDataChange()
375 iterator = NetworkData::kIteratorInit; in RecordNetworkDataChange()
377 while (Get<NetworkData::Leader>().GetNextOnMeshPrefix(iterator, prefix) == kErrorNone) in RecordNetworkDataChange()
387 iterator = NetworkData::kIteratorInit; in RecordNetworkDataChange()
389 while (mPreviousNetworkData.GetNextExternalRoute(iterator, route) == kErrorNone) in RecordNetworkDataChange()
397 iterator = NetworkData::kIteratorInit; in RecordNetworkDataChange()
399 while (Get<NetworkData::Leader>().GetNextExternalRoute(iterator, route) == kErrorNone) in RecordNetworkDataChange()
/openthread-3.6.0/tests/unit/
Dtest_network_data.cpp687 Service::Manager::Iterator iterator; in TestNetworkDataDsnSrpServices() local
702 SuccessOrQuit(manager.GetNextDnsSrpAnycastInfo(iterator, anycastInfo)); in TestNetworkDataDsnSrpServices()
710 VerifyOrQuit(manager.GetNextDnsSrpAnycastInfo(iterator, anycastInfo) == kErrorNotFound, in TestNetworkDataDsnSrpServices()
726 iterator.Clear(); in TestNetworkDataDsnSrpServices()
730 SuccessOrQuit(manager.GetNextDnsSrpUnicastInfo(iterator, unicastInfo)); in TestNetworkDataDsnSrpServices()
737 VerifyOrQuit(manager.GetNextDnsSrpUnicastInfo(iterator, unicastInfo) == kErrorNotFound, in TestNetworkDataDsnSrpServices()
899 Service::Manager::Iterator iterator; in TestNetworkDataDsnSrpAnycastSeqNumSelection() local
909 SuccessOrQuit(manager.GetNextDnsSrpAnycastInfo(iterator, anycastInfo)); in TestNetworkDataDsnSrpAnycastSeqNumSelection()
917 VerifyOrQuit(manager.GetNextDnsSrpAnycastInfo(iterator, anycastInfo) == kErrorNotFound); in TestNetworkDataDsnSrpAnycastSeqNumSelection()
/openthread-3.6.0/src/core/border_router/
Drouting_manager.cpp446 NetworkData::Iterator iterator = NetworkData::kIteratorInit; in UpdateDiscoveredPrefixTableOnNetDataChange() local
453 while (Get<NetworkData::Leader>().GetNextOnMeshPrefix(iterator, prefixConfig) == kErrorNone) in UpdateDiscoveredPrefixTableOnNetDataChange()
908 NetworkData::Iterator iterator = NetworkData::kIteratorInit; in NetworkDataContainsOmrPrefix() local
912 … while (Get<NetworkData::Leader>().GetNextOnMeshPrefix(iterator, onMeshPrefixConfig) == kErrorNone) in NetworkDataContainsOmrPrefix()
930 NetworkData::Iterator iterator = NetworkData::kIteratorInit; in NetworkDataContainsUlaRoute() local
934 while (Get<NetworkData::Leader>().GetNextExternalRoute(iterator, routeConfig) == kErrorNone) in NetworkDataContainsUlaRoute()
1705 Iterator &iterator = static_cast<Iterator &>(aIterator); in GetNextEntry() local
1707 VerifyOrExit(iterator.GetRouter() != nullptr, error = kErrorNotFound); in GetNextEntry()
1708 OT_ASSERT(iterator.GetEntry() != nullptr); in GetNextEntry()
1710 iterator.GetRouter()->CopyInfoTo(aEntry.mRouter); in GetNextEntry()
[all …]
/openthread-3.6.0/src/core/backbone_router/
Dbbr_leader.cpp219 NetworkData::Iterator iterator = NetworkData::kIteratorInit; in UpdateDomainPrefixConfig() local
224 while (Get<NetworkData::Leader>().GetNextOnMeshPrefix(iterator, config) == kErrorNone) in UpdateDomainPrefixConfig()
/openthread-3.6.0/src/core/radio/
Dtrel_interface.cpp255 Dns::TxtEntry::Iterator iterator; in ParsePeerInfoTxtData() local
261 iterator.Init(aInfo.GetTxtData(), aInfo.GetTxtLength()); in ParsePeerInfoTxtData()
263 while ((error = iterator.GetNextEntry(entry)) == kErrorNone) in ParsePeerInfoTxtData()

12