class PimVif
|
A class for PIM-specific virtual interface.
More... |
|
|
Public Methods
- PimVif (PimNode& pim_node, const Vif& vif)
- virtual ~PimVif ()
- int start ()
- int stop ()
- int final_stop ()
- int pim_recv (const IPvX& src, const IPvX& dst,
int ip_ttl, int ip_tos, bool router_alert_bool,
buffer_t *buffer)
- string flags_string (void) const
- PimNode& pim_node () const
- PimMrt& pim_mrt () const
- PimNbr& pim_nbr_me ()
- void pim_hello_start ()
- void pim_hello_stop ()
- void pim_hello_stop_dr ()
- void pim_dr_elect ()
- bool i_may_become_dr (const IPvX& exclude_addr)
- const IPvX& addr () const
- const IPvX& dr_addr () const
- void set_default_config ()
- int set_proto_version (int proto_version)
- ConfigParam<uint16_t>& hello_triggered_delay ()
- ConfigParam<uint16_t>& hello_period ()
- ConfigParam<uint16_t>& hello_holdtime ()
- ConfigParam<uint32_t>& genid ()
- ConfigParam<uint32_t>& dr_priority ()
- ConfigParam<uint16_t>& lan_delay ()
- ConfigParam<uint16_t>& override_interval ()
- ConfigParam<bool>& accept_nohello_neighbors ()
- ConfigParam<uint16_t>& join_prune_period ()
- ConfigParam<uint16_t>& join_prune_holdtime ()
- ConfigParam<uint32_t>& assert_time ()
- ConfigParam<uint32_t>& assert_override_interval ()
- int pim_hello_send ()
- int pim_hello_first_send ()
- int pim_join_prune_send (PimNbr *pim_nbr, PimJpHeader *jp_header)
- int pim_assert_mre_send (PimMre *pim_mre,
const IPvX& assert_source_addr)
- int pim_assert_cancel_send (PimMre *pim_mre)
- int pim_assert_send (const IPvX& assert_source_addr,
const IPvX& assert_group_addr,
uint32_t group_masklen,
uint32_t route_metric,
uint32_t metric_preference)
- int pim_register_send (const IPvX& rp_addr,
const IPvX& source_addr,
const IPvX& group_addr,
const uint8_t *rcvbuf,
size_t rcvlen)
- int pim_register_null_send (const IPvX& rp_addr,
const IPvX& source_addr,
const IPvX& group_addr)
- int pim_register_stop_send (const IPvX& dr_addr,
const IPvX& source_addr,
const IPvX& group_addr)
- int pim_bootstrap_send (const IPvX& dst_addr,
const BsrZone& bsr_zone)
- buffer_t * pim_bootstrap_send_prepare (const IPvX& dst_addr,
const BsrZone& bsr_zone,
bool is_first_fragment)
- int pim_cand_rp_adv_send (const BsrZone& bsr_zone)
- void hello_timer_start (uint32_t sec, uint32_t usec)
- void hello_timer_start_random (uint32_t sec, uint32_t usec)
- bool is_lan_delay_enabled () const
- const struct timeval& vif_propagation_delay () const
- const struct timeval& vif_override_interval () const
- bool is_lan_suppression_state_enabled () const
- const struct timeval& upstream_join_timer_t_suppressed () const
- const struct timeval& upstream_join_timer_t_override () const
- const struct timeval& jp_override_interval () const
- list<PimNbr *>& pim_nbrs ()
- int pim_nbrs_number () const
- bool i_am_dr () const
- void set_i_am_dr (bool v)
- PimNbr * pim_nbr_find (const IPvX& nbr_addr)
- void add_pim_nbr (PimNbr *pim_nbr)
- int delete_pim_nbr (PimNbr *pim_nbr)
- void delete_pim_nbr_from_nbr_list (PimNbr *pim_nbr)
- void incr_usage_by_pim_mre_task ()
- void decr_usage_by_pim_mre_task ()
Constructor for a given PIM node and a generic virtual interface.
Parameters:
pim_node | the PimNode this interface belongs to.
|
vif | the generic Vif interface that contains various information.
|
[virtual]
Destructor
Start PIM on a single virtual interface.
Returns: XORP_OK on success, otherwise XORP_ERROR.
Reimplemented from ProtoUnit.
Gracefully stop PIM on a single virtual interface.
The graceful stop will attempt to send Join/Prune, Assert, etc.
messages for all multicast routing entries to gracefully clean-up
state with neighbors.
After the multicast routing entries cleanup is completed,
PimVif::final_stop() is called to complete the job.
If this method is called one-after-another, the second one
will force calling immediately PimVif::final_stop() to quickly
finish the job.
Returns: XORP_OK on success, otherwise XORP_ERROR.
Reimplemented from ProtoUnit.
int final_stop ()
| final_stop |
Completely stop PIM on a single virtual interface.
This method should be called after PimVif::stop() to complete
the job.
Returns: XORP_OK on success, otherwise XORP_ERROR.
int pim_recv (const IPvX& src, const IPvX& dst,
int ip_ttl, int ip_tos, bool router_alert_bool,
buffer_t *buffer)
| pim_recv |
Receive a protocol message.
Parameters:
src | the source address of the message.
|
dst | the destination address of the message.
|
ip_ttl | the IP TTL of the message. If it has a negative value
it should be ignored.
|
ip_ttl | the IP TOS of the message. If it has a negative value,
it should be ignored.
|
router_alert_bool | if true, the IP Router Alert option in
the IP packet was set (when applicable).
|
buffer | the data buffer with the received message.
|
Returns: XORP_OK on success, otherwise XORP_ERROR.
string flags_string (void)
| flags_string |
[const]
Get the string with the flags about the vif status.
TODO: temporary here. Should go to the Vif class after the Vif
class starts using the Proto class.
Returns: the C++ style string with the flags about the vif status
(e.g., UP/DOWN/DISABLED, etc).
[const]
Get the PIM node (PimNode).
Returns: a reference to the PIM node (PimNode).
[const]
Get the PIM Multicast Routing Table (PimMrt).
Returns: a reference to the PIM Multicast Routing Table (PimMrt).
PimNbr& pim_nbr_me ()
| pim_nbr_me |
Get the PIM neighbor information (PimNbr) about myself.
Returns: a reference to the PIM neighbor information (PimNbr)
about myself.
void pim_hello_start ()
| pim_hello_start |
Start the PIM Hello operation.
void pim_hello_stop ()
| pim_hello_stop |
Stop the PIM Hello operation.
void pim_hello_stop_dr ()
| pim_hello_stop_dr |
Attempt to inform other PIM neighbors that this interface is not more
the Designated Router.
void pim_dr_elect ()
| pim_dr_elect |
Elect a Designated Router on this interface.
bool i_may_become_dr (const IPvX& exclude_addr)
| i_may_become_dr |
Compute if I may become the Designated Router on this interface
if one of the PIM neighbor addresses is not considered.
Compute if I may become the DR on this interface if exclude_addr
is excluded.
Parameters:
exclude_addr | the address to exclude in the computation.
|
Returns: true if I may become the DR on this interface, otherwise
false.
[const]
Get my primary address on this interface.
Returns: my primary address on this interface.
const IPvX& dr_addr ()
| dr_addr |
[const]
Get the address of the Designated Router on this interface.
Returns: the address of the Designated Router on this interface.
void set_default_config ()
| set_default_config |
Set configuration to default values.
int set_proto_version (int proto_version)
| set_proto_version |
Set the current protocol version.
The protocol version must be in the interval
[PIM_VERSION_MIN, PIM_VERSION_MAX].
Parameters:
proto_version | the protocol version to set.
|
Returns: XORP_OK on success, otherwise XORP_ERROR.
Reimplemented from ProtoUnit.
ConfigParam<uint16_t>& hello_triggered_delay ()
| hello_triggered_delay |
ConfigParam<uint16_t>& hello_holdtime ()
| hello_holdtime |
ConfigParam<uint16_t>& override_interval ()
| override_interval |
ConfigParam<bool>& accept_nohello_neighbors ()
| accept_nohello_neighbors |
ConfigParam<uint16_t>& join_prune_period ()
| join_prune_period |
ConfigParam<uint16_t>& join_prune_holdtime ()
| join_prune_holdtime |
ConfigParam<uint32_t>& assert_override_interval ()
| assert_override_interval |
int pim_hello_send ()
| pim_hello_send |
int pim_hello_first_send ()
| pim_hello_first_send |
int pim_join_prune_send (PimNbr *pim_nbr, PimJpHeader *jp_header)
| pim_join_prune_send |
int pim_assert_mre_send (PimMre *pim_mre,
const IPvX& assert_source_addr)
| pim_assert_mre_send |
int pim_assert_cancel_send (PimMre *pim_mre)
| pim_assert_cancel_send |
int pim_assert_send (const IPvX& assert_source_addr,
const IPvX& assert_group_addr,
uint32_t group_masklen,
uint32_t route_metric,
uint32_t metric_preference)
| pim_assert_send |
int pim_register_send (const IPvX& rp_addr,
const IPvX& source_addr,
const IPvX& group_addr,
const uint8_t *rcvbuf,
size_t rcvlen)
| pim_register_send |
int pim_register_null_send (const IPvX& rp_addr,
const IPvX& source_addr,
const IPvX& group_addr)
| pim_register_null_send |
int pim_register_stop_send (const IPvX& dr_addr,
const IPvX& source_addr,
const IPvX& group_addr)
| pim_register_stop_send |
int pim_bootstrap_send (const IPvX& dst_addr,
const BsrZone& bsr_zone)
| pim_bootstrap_send |
buffer_t * pim_bootstrap_send_prepare (const IPvX& dst_addr,
const BsrZone& bsr_zone,
bool is_first_fragment)
| pim_bootstrap_send_prepare |
int pim_cand_rp_adv_send (const BsrZone& bsr_zone)
| pim_cand_rp_adv_send |
void hello_timer_start (uint32_t sec, uint32_t usec)
| hello_timer_start |
void hello_timer_start_random (uint32_t sec, uint32_t usec)
| hello_timer_start_random |
bool is_lan_delay_enabled ()
| is_lan_delay_enabled |
[const]
const struct timeval& vif_propagation_delay ()
| vif_propagation_delay |
[const]
const struct timeval& vif_override_interval ()
| vif_override_interval |
[const]
bool is_lan_suppression_state_enabled ()
| is_lan_suppression_state_enabled |
[const]
const struct timeval& upstream_join_timer_t_suppressed ()
| upstream_join_timer_t_suppressed |
[const]
const struct timeval& upstream_join_timer_t_override ()
| upstream_join_timer_t_override |
[const]
const struct timeval& jp_override_interval ()
| jp_override_interval |
[const]
list<PimNbr *>& pim_nbrs ()
| pim_nbrs |
int pim_nbrs_number ()
| pim_nbrs_number |
[const]
[const]
void set_i_am_dr (bool v)
| set_i_am_dr |
PimNbr * pim_nbr_find (const IPvX& nbr_addr)
| pim_nbr_find |
void add_pim_nbr (PimNbr *pim_nbr)
| add_pim_nbr |
int delete_pim_nbr (PimNbr *pim_nbr)
| delete_pim_nbr |
void delete_pim_nbr_from_nbr_list (PimNbr *pim_nbr)
| delete_pim_nbr_from_nbr_list |
void incr_usage_by_pim_mre_task ()
| incr_usage_by_pim_mre_task |
void decr_usage_by_pim_mre_task ()
| decr_usage_by_pim_mre_task |
Generated by: pavlin on possum.icir.org on Wed Dec 11 16:50:53 2002, using kdoc 2.0a54+XORP. |