Class: PacketGen::Header::OSPFv3::ArrayOfLSA

Inherits:
Types::Array show all
Defined in:
lib/packetgen/header/ospfv3/lsa.rb

Overview

This class defines a specialized array to handle series of LSAs or LSAHeaders. It recognizes known LSA types and infers correct type.

Author:

  • Sylvain Daubert

Since:

  • 2.5.0

Constant Summary

Constants inherited from Types::Array

Types::Array::HUMAN_SEPARATOR

Constants included from Types::LengthFrom

Types::LengthFrom::MAX_SZ_TO_READ

Instance Method Summary collapse

Methods inherited from Types::Array

#<<, #==, #[], #clear, #clear!, #delete, #delete_at, #each, #empty?, #first, #initialize_copy, #last, #push, #read, set_of, set_of_klass, #size, #sz, #to_a, #to_human, #to_s

Methods included from Types::LengthFrom

#initialize_length_from, #read_with_length_from, #sz_to_read

Methods included from Types::Fieldable

#format_inspect, #read, #sz, #to_human, #to_s, #type_name

Constructor Details

#initialize(options = {}) ⇒ ArrayOfLSA

Returns a new instance of ArrayOfLSA.

Parameters:

  • options (Hash) (defaults to: {})

Options Hash (options):

  • counter (Types::Int)

    Int object used as a counter for this set

  • only_headers (Boolean)

    if true, only LSAHeaders will be added to this array.

Since:

  • 2.5.0



194
195
196
197
# File 'lib/packetgen/header/ospfv3/lsa.rb', line 194

def initialize(options={})
  super
  @only_headers = options[:only_headers] || false
end