mirror of
https://github.com/espressif/openthread.git
synced 2026-08-02 17:17:45 +00:00
[ip6] expose static multicast address getters and remove wrapper methods (#12416)
This commit updates `Ip6::Address` to expose `static` getter methods for common multicast addresses (e.g., `GetLinkLocalAllNodesMulticast()`) as public API. Consequentially, the wrapper `SetTo...` and `Is...` methods for these multicast addresses are removed. Callers are updated to use the `static` getters directly. This change simplifies usage by allowing direct access to the constant address instances, often eliminating the need for local `Ip6::Address` variables.
This commit is contained in:
@@ -58,7 +58,7 @@ void MessageInfo::SetSockAddrToRlocPeerAddrToLeaderRloc(void)
|
||||
void MessageInfo::SetSockAddrToRlocPeerAddrToRealmLocalAllRoutersMulticast(void)
|
||||
{
|
||||
SetSockAddrToRloc();
|
||||
GetPeerAddr().SetToRealmLocalAllRoutersMulticast();
|
||||
SetPeerAddr(Ip6::Address::GetRealmLocalAllRoutersMulticast());
|
||||
}
|
||||
|
||||
void MessageInfo::SetSockAddrToRlocPeerAddrTo(uint16_t aRloc16)
|
||||
|
||||
Reference in New Issue
Block a user