Class: Pio::Dhcp::OptionalTlv

Inherits:
BinData::Record
  • Object
show all
Defined in:
lib/pio/dhcp/optional_tlv.rb

Overview

DHCP Optional TLV

Constant Summary collapse

DEFAULT =
'default'

Instance Method Summary collapse

Instance Method Details

#chooserObject



36
37
38
39
40
41
42
# File 'lib/pio/dhcp/optional_tlv.rb', line 36

def chooser
  if valid_optional_tlv?
    tlv_type
  else
    DEFAULT
  end
end

#end_of_dhcpdu?Boolean

Returns:

  • (Boolean)


44
45
46
# File 'lib/pio/dhcp/optional_tlv.rb', line 44

def end_of_dhcpdu?
  tlv_type == Dhcp::END_OF_TLV
end

#end_of_dhcptlv?Boolean

Returns:

  • (Boolean)


32
33
34
# File 'lib/pio/dhcp/optional_tlv.rb', line 32

def end_of_dhcptlv?
  tlv_type == Dhcp::END_OF_TLV
end