34 #ifndef NET_NETIF_HPP_ 35 #define NET_NETIF_HPP_ 113 return mScopeOverrideValid ?
static_cast<uint8_t
>(mScopeOverride) : GetAddress().GetScope();
204 mCallback = aCallback;
214 bool IsFree(
void) {
return (mCallback == NULL); }
236 return (aCallback == mCallback && aContext == mContext);
240 void Callback(uint32_t aFlags) {
241 if (mCallback != NULL) {
242 mCallback(aFlags, mContext);
343 void RemoveAllExternalUnicastAddresses(
void);
353 bool IsUnicastAddress(
const Address &aAddress)
const;
364 bool IsMulticastSubscribed(
const Address &aAddress)
const;
373 otError SubscribeAllRoutersMulticast(
void);
382 otError UnsubscribeAllRoutersMulticast(
void);
443 void UnsubscribeAllExternalMulticastAddresses(
void);
497 void SetStateChangedFlags(uint32_t aFlags);
531 uint8_t *aPrefixMatch) = 0;
534 static void HandleStateChangedTask(
Tasklet &aTasklet);
535 void HandleStateChangedTask(
void);
542 bool mMulticastPromiscuous;
546 uint32_t mStateChangedFlags;
566 #endif // NET_NETIF_HPP_ NetifUnicastAddress * GetNext(void)
This method returns the next unicast address assigned to the interface.
Definition: netif.hpp:130
bool IsServing(otStateChangedCallback aCallback, void *aContext)
This method tests whether the object is set to the provided elements.
Definition: netif.hpp:235
bool IsFree(void)
This method tests whether the object is free or in use.
Definition: netif.hpp:214
This type represents all the static / global variables used by OpenThread allocated in one place...
Definition: openthread-instance.h:59
void Free(void)
This method frees the object.
Definition: netif.hpp:220
const NetifUnicastAddress * GetNext(void) const
This method returns the next unicast address assigned to the interface.
Definition: netif.hpp:122
const NetifUnicastAddress * GetUnicastAddresses(void) const
This method returns a pointer to the list of unicast addresses.
Definition: netif.hpp:290
This file includes definitions for IPv6 addresses.
This class implements an IPv6 address object.
Definition: ip6_address.hpp:60
uint8_t mLength
Length of link address.
Definition: netif.hpp:77
This file includes definitions for locator class for OpenThread objects.
Address & GetAddress(void)
This method returns the multicast address.
Definition: netif.hpp:156
This class implements an IPv6 network interface multicast address.
Definition: netif.hpp:137
Address & GetAddress(void)
This method returns the unicast address.
Definition: netif.hpp:104
This class represents an IPv6 Link Address.
Definition: netif.hpp:65
#define OPENTHREAD_CONFIG_MAX_EXT_IP_ADDRS
The maximum number of supported IPv6 addresses allows to be externally added.
Definition: openthread-core-default-config.h:271
This class is used to represent a tasklet.
Definition: tasklet.hpp:64
void Set(otStateChangedCallback aCallback, void *aContext)
This method sets the callback information.
Definition: netif.hpp:203
This class implements the core IPv6 message processing.
Definition: ip6.hpp:101
const Address & GetAddress(void) const
This method returns the unicast address.
Definition: netif.hpp:96
This structure represents an IPv6 network interface unicast address.
Definition: types.h:1089
This structure represents an IEEE 802.15.4 Extended Address.
Definition: mac_frame.hpp:84
const Address & GetAddress(void) const
This method returns the multicast address.
Definition: netif.hpp:148
This file includes definitions for generating and processing IEEE 802.15.4 MAC frames.
NetifMulticastAddress * GetNext(void)
This method returns the next multicast address subscribed to the interface.
Definition: netif.hpp:172
This class implements an IPv6 network interface unicast address.
Definition: netif.hpp:85
This class implements definitions for maintaining a pointer to arbitrary context information.
Definition: context.hpp:61
This class represents a message.
Definition: message.hpp:195
This file includes definitions for tasklets and the tasklet scheduler.
HardwareType mType
Link address type.
Definition: netif.hpp:76
bool IsMulticastPromiscuousEnabled(void)
This method checks if multicast promiscuous mode is enabled on the network interface.
Definition: netif.hpp:451
HardwareType
Hardware types.
Definition: netif.hpp:72
This file includes definitions for IPv6 sockets.
This file includes definitions for the message buffer pool and message buffers.
This class implements locator for otInstance object.
Definition: locator.hpp:63
#define OPENTHREAD_CONFIG_MAX_EXT_MULTICAST_IP_ADDRS
The maximum number of supported IPv6 multicast addresses allows to be externally added.
Definition: openthread-core-default-config.h:281
Netif * GetNext(void) const
This method returns the next network interface in the list.
Definition: netif.hpp:274
bool IsStateChangedCallbackPending(void)
This method indicates whether or not a state changed callback is pending.
Definition: netif.hpp:487
void SetMulticastPromiscuous(bool aEnabled)
This method enables multicast promiscuous mode on the network interface.
Definition: netif.hpp:459
void(OTCALL * otStateChangedCallback)(uint32_t aFlags, void *aContext)
This function pointer is called to notify certain configuration or state changes within OpenThread...
Definition: instance.h:230
uint8_t GetScope(void) const
This method returns the IPv6 scope value.
Definition: netif.hpp:112
Mac::ExtAddress mExtAddress
Link address.
Definition: netif.hpp:78
NetifCallback(void)
This constructor initializes the object.
Definition: netif.hpp:190
const NetifMulticastAddress * GetMulticastAddresses(void) const
This method returns a pointer to the list of multicast addresses.
Definition: netif.hpp:390
This class implements network interface handlers.
Definition: netif.hpp:181
const NetifMulticastAddress * GetNext(void) const
This method returns the next multicast address subscribed to the interface.
Definition: netif.hpp:164
This class implements an IPv6 network interface.
Definition: netif.hpp:255
This structure represents an IPv6 network interface multicast address.
Definition: types.h:1105
otError
This enumeration represents error codes used throughout OpenThread.
Definition: types.h:107
This file includes compile-time configuration constants for OpenThread.
int8_t GetInterfaceId(void) const
This method returns the network interface identifier.
Definition: netif.hpp:282