A Discrete-Event Network Simulator
API
Loading...
Searching...
No Matches
ns3::IaAddressOption Class Reference

Implements the IA Address options. More...

#include "dhcp6-options.h"

+ Inheritance diagram for ns3::IaAddressOption:
+ Collaboration diagram for ns3::IaAddressOption:

Public Member Functions

 IaAddressOption ()
 Default constructor.
 
 IaAddressOption (Ipv6Address iaAddress, uint32_t preferredLifetime, uint32_t validLifetime)
 Constructor.
 
Ipv6Address GetIaAddress () const
 Get the IA Address.
 
uint32_t GetPreferredLifetime () const
 Get the preferred lifetime.
 
uint32_t GetValidLifetime () const
 Get the valid lifetime.
 
void SetIaAddress (Ipv6Address iaAddress)
 Set the IA Address.
 
void SetPreferredLifetime (uint32_t preferredLifetime)
 Set the preferred lifetime.
 
void SetValidLifetime (uint32_t validLifetime)
 Set the valid lifetime.
 
- Public Member Functions inherited from ns3::Options
 Options ()
 Default constructor.
 
 Options (OptionType code, uint16_t length)
 Constructor.
 
OptionType GetOptionCode () const
 Get the option code.
 
uint16_t GetOptionLength () const
 Get the option length.
 
void SetOptionCode (OptionType code)
 Set the option code.
 
void SetOptionLength (uint16_t length)
 Set the option length.
 

Private Attributes

Ipv6Address m_iaAddress
 the IPv6 address offered to the client.
 
uint32_t m_preferredLifetime
 The preferred lifetime of the address, in seconds.
 
StatusCodeOption m_statusCodeOption
 (optional) The status code of any operation involving this address
 
uint32_t m_validLifetime
 The valid lifetime of the address, in seconds.
 

Additional Inherited Members

- Public Types inherited from ns3::Options
enum class  OptionType {
  OPTION_INIT = 0 , OPTION_CLIENTID = 1 , OPTION_SERVERID = 2 , OPTION_IA_NA = 3 ,
  OPTION_IA_TA = 4 , OPTION_IAADDR = 5 , OPTION_ORO = 6 , OPTION_PREFERENCE = 7 ,
  OPTION_ELAPSED_TIME = 8 , OPTION_RELAY_MSG = 9 , OPTION_AUTH = 11 , OPTION_UNICAST = 12 ,
  OPTION_STATUS_CODE = 13 , OPTION_RAPID_COMMIT = 14 , OPTION_USER_CLASS = 15 , OPTION_VENDOR_CLASS = 16 ,
  OPTION_VENDOR_OPTS = 17 , OPTION_INTERFACE_ID = 18 , OPTION_RECONF_MSG = 19 , OPTION_RECONF_ACCEPT = 20 ,
  OPTION_IA_PD = 25 , OPTION_IAPREFIX = 26 , OPTION_INFORMATION_REFRESH_TIME = 32 , OPTION_SOL_MAX_RT = 82 ,
  OPTION_INF_MAX_RT = 83
}
 Enum to identify the option type. More...
 
enum class  StatusCodeValues {
  Success = 0 , UnspecFail = 1 , NoAddrsAvail = 2 , NoBinding = 3 ,
  NotOnLink = 4 , UseMulticast = 5 , NoPrefixAvail = 6
}
 Enum to identify the status code of the operation. More...
 

Detailed Description

Implements the IA Address options.

Definition at line 223 of file dhcp6-options.h.

Constructor & Destructor Documentation

◆ IaAddressOption() [1/2]

ns3::IaAddressOption::IaAddressOption ( )

Default constructor.

Definition at line 136 of file dhcp6-options.cc.

References m_iaAddress, m_preferredLifetime, and m_validLifetime.

◆ IaAddressOption() [2/2]

ns3::IaAddressOption::IaAddressOption ( Ipv6Address iaAddress,
uint32_t preferredLifetime,
uint32_t validLifetime )

Constructor.

Parameters
iaAddressThe IA Address.
preferredLifetimeThe preferred lifetime of the address.
validLifetimeThe valid lifetime of the address.

Definition at line 143 of file dhcp6-options.cc.

References m_iaAddress, m_preferredLifetime, and m_validLifetime.

Member Function Documentation

◆ GetIaAddress()

Ipv6Address ns3::IaAddressOption::GetIaAddress ( ) const

Get the IA Address.

Returns
the IPv6 address of the Identity Association

Definition at line 153 of file dhcp6-options.cc.

References m_iaAddress.

◆ GetPreferredLifetime()

uint32_t ns3::IaAddressOption::GetPreferredLifetime ( ) const

Get the preferred lifetime.

Returns
the preferred lifetime

Definition at line 166 of file dhcp6-options.cc.

References m_preferredLifetime.

◆ GetValidLifetime()

uint32_t ns3::IaAddressOption::GetValidLifetime ( ) const

Get the valid lifetime.

Returns
the lifetime for which the address is valid.

Definition at line 179 of file dhcp6-options.cc.

References m_validLifetime.

◆ SetIaAddress()

void ns3::IaAddressOption::SetIaAddress ( Ipv6Address iaAddress)

Set the IA Address.

Parameters
iaAddressthe IPv6 address of this Identity Association.

Definition at line 159 of file dhcp6-options.cc.

References m_iaAddress, and NS_LOG_FUNCTION.

Referenced by ns3::Dhcp6Header::AddAddress(), and ns3::Dhcp6Header::Deserialize().

+ Here is the caller graph for this function:

◆ SetPreferredLifetime()

void ns3::IaAddressOption::SetPreferredLifetime ( uint32_t preferredLifetime)

Set the preferred lifetime.

Parameters
preferredLifetimethe preferred lifetime for this address.

Definition at line 172 of file dhcp6-options.cc.

References m_preferredLifetime, and NS_LOG_FUNCTION.

Referenced by ns3::Dhcp6Header::AddAddress(), and ns3::Dhcp6Header::Deserialize().

+ Here is the caller graph for this function:

◆ SetValidLifetime()

void ns3::IaAddressOption::SetValidLifetime ( uint32_t validLifetime)

Set the valid lifetime.

Parameters
validLifetimethe lifetime for which the address is valid.

Definition at line 185 of file dhcp6-options.cc.

References m_validLifetime, and NS_LOG_FUNCTION.

Referenced by ns3::Dhcp6Header::AddAddress(), and ns3::Dhcp6Header::Deserialize().

+ Here is the caller graph for this function:

Member Data Documentation

◆ m_iaAddress

Ipv6Address ns3::IaAddressOption::m_iaAddress
private

the IPv6 address offered to the client.

Definition at line 276 of file dhcp6-options.h.

Referenced by IaAddressOption(), IaAddressOption(), GetIaAddress(), and SetIaAddress().

◆ m_preferredLifetime

uint32_t ns3::IaAddressOption::m_preferredLifetime
private

The preferred lifetime of the address, in seconds.

Definition at line 277 of file dhcp6-options.h.

Referenced by IaAddressOption(), IaAddressOption(), GetPreferredLifetime(), and SetPreferredLifetime().

◆ m_statusCodeOption

StatusCodeOption ns3::IaAddressOption::m_statusCodeOption
private

(optional) The status code of any operation involving this address

Definition at line 281 of file dhcp6-options.h.

◆ m_validLifetime

uint32_t ns3::IaAddressOption::m_validLifetime
private

The valid lifetime of the address, in seconds.

Definition at line 278 of file dhcp6-options.h.

Referenced by IaAddressOption(), IaAddressOption(), GetValidLifetime(), and SetValidLifetime().


The documentation for this class was generated from the following files: