Class: Nl::Linux::NetShaper::AttributeSets::LeafInfo

Inherits:
AttributeSet
  • Object
show all
Defined in:
nl-linux/generated/nl/linux/net_shaper.rb

Defined Under Namespace

Classes: Attribute, Handle, Priority, Weight

Constant Summary

Constants inherited from AttributeSet

AttributeSet::SELECTOR_NAMES

Class Method Summary collapse

Instance Method Summary collapse

Methods inherited from AttributeSet

#<<, #[], build_attributes, decode, #encode, #initialize

Constructor Details

This class inherits a constructor from Nl::AttributeSet

Class Method Details

.by_name(name) ⇒ Attribute

Looks up Attribute class by name.

Parameters:

  • name (Symbol)

Returns:



385
# File 'nl-linux/generated/nl/linux/net_shaper.rb', line 385

def by_name(name); BY_NAME.fetch(name); end

.by_type(type) ⇒ Attribute

Looks up Attribute class by type value.

Parameters:

  • type (Integer)

Returns:



391
# File 'nl-linux/generated/nl/linux/net_shaper.rb', line 391

def by_type(type); BY_TYPE.fetch(type); end

Instance Method Details

#handle ⇒ AttributeSets::Handle

Unique identifier for the given shaper inside the owning device.

Returns:

See Also:



364
# File 'nl-linux/generated/nl/linux/net_shaper.rb', line 364

def handle; self[:"handle"]&.value; end

#priority ⇒ Integer

Scheduling priority for the given shaper. The priority scheduling is applied to sibling shapers.

Returns:

  • (Integer)

See Also:



370
# File 'nl-linux/generated/nl/linux/net_shaper.rb', line 370

def priority; self[:"priority"]&.value; end

#weight ⇒ Integer

Relative weight for round robin scheduling of the given shaper. The scheduling is applied to all sibling shapers with the same priority.

Returns:

  • (Integer)

See Also:



378
# File 'nl-linux/generated/nl/linux/net_shaper.rb', line 378

def weight; self[:"weight"]&.value; end