Class: PacketGen::Header::DHCPv6::Preference

Inherits:
Option
  • Object
show all
Defined in:
lib/packetgen/header/dhcpv6/option.rb

Overview

DHCPv6 Preference option

Author:

  • Sylvain Daubert

Since:

  • 2.5.0

Instance Attribute Summary collapse

Attributes inherited from Option

#length, #type

Instance Method Summary collapse

Methods inherited from Option

human_type, initialize, new, subclasses, to_human

Instance Attribute Details

#valueInteger

8-bit value

Returns:

  • (Integer)


248
# File 'lib/packetgen/header/dhcpv6/option.rb', line 248

define_attr :value, BinStruct::Int8

Instance Method Details

#human_dataString

Get human-readable data (value)

Returns:

  • (String)

Since:

  • 2.5.0



252
253
254
# File 'lib/packetgen/header/dhcpv6/option.rb', line 252

def human_data
  value.to_s
end