Class: Nl::Linux::Nftables::AttributeSets::CounterAttrs

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

Defined Under Namespace

Classes: Attribute, Bytes, Packets, Pad

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:



990
# File 'nl-linux/generated/nl/linux/nftables.rb', line 990

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

.by_type(type) ⇒ Attribute

Looks up Attribute class by type value.

Parameters:

  • type (Integer)

Returns:



996
# File 'nl-linux/generated/nl/linux/nftables.rb', line 996

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

Instance Method Details

#bytes ⇒ Integer

Returns:

  • (Integer)

See Also:



979
# File 'nl-linux/generated/nl/linux/nftables.rb', line 979

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

#packets ⇒ Integer

Returns:

  • (Integer)

See Also:



983
# File 'nl-linux/generated/nl/linux/nftables.rb', line 983

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