Module: OSPFv2::Tlv::Common

Included in:
Link_Tlv
Defined in:
lib/lsa/tlv/tlv.rb

Instance Method Summary collapse

Instance Method Details

#stlv_len(n) ⇒ Object



17
18
19
# File 'lib/lsa/tlv/tlv.rb', line 17

def stlv_len(n)
  (((n+3)/4)*4)+4
end

#tlv_lenObject



20
21
22
# File 'lib/lsa/tlv/tlv.rb', line 20

def tlv_len
  @length
end

#to_hashObject



23
24
25
# File 'lib/lsa/tlv/tlv.rb', line 23

def to_hash
  {:tlv_type=> tlv_type}
end