Class: OSPFv2::NeighborState::ExStart
- Defined in:
- lib/neighbor_sm/exstart_state.rb
Instance Method Summary collapse
- #adj_ok? ⇒ Boolean
-
#initialize(n) ⇒ ExStart
constructor
A new instance of ExStart.
- #negotiation_done ⇒ Object
Methods inherited from State
#bad_ls_req, #change_state, #inactivity_timer, #kill_nbr, #method_missing, #one_way_received, #recv_hello, #seq_number_mismatch, #two_way_received
Constructor Details
#initialize(n) ⇒ ExStart
Returns a new instance of ExStart.
28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 |
# File 'lib/neighbor_sm/exstart_state.rb', line 28 def initialize(n) @neighbor = n n.instance_eval do @last_dd_seqn = n.dd_sequence_number #-- could be a State#reset method inherited ? @ls_db.reset if @ls_db @ls_req_list={} @periodic_refresh.cancel @periodic_rxmt.cancel #-- @last_dd_seqn = dd_sequence_number raise unless @last_dd_seqn>0 dd = DatabaseDescription.new :router_id=> @router_id, :area_id=> @area_id, :imms=>7, :dd_sequence_number => @last_dd_seqn send_dd dd, true end end |
Dynamic Method Handling
This class handles dynamic methods through the method_missing method in the class OSPFv2::NeighborState::State
Instance Method Details
#adj_ok? ⇒ Boolean
57 58 59 60 61 62 |
# File 'lib/neighbor_sm/exstart_state.rb', line 57 def adj_ok? if ! ok change_state(@neighbor, Two_way.new) end end |