Class: OsCtl::Lib::LoadAvgReader::LoadAvg
- Inherits:
-
Struct
- Object
- Struct
- OsCtl::Lib::LoadAvgReader::LoadAvg
- Defined in:
- lib/libosctl/loadavg_reader.rb
Instance Attribute Summary collapse
-
#avg ⇒ Object
Returns the value of attribute avg.
-
#ctid ⇒ Object
Returns the value of attribute ctid.
-
#pool_name ⇒ Object
Returns the value of attribute pool_name.
-
#runnable ⇒ Object
Returns the value of attribute runnable.
-
#total ⇒ Object
Returns the value of attribute total.
Instance Method Summary collapse
Instance Attribute Details
#avg ⇒ Object
Returns the value of attribute avg
9 10 11 |
# File 'lib/libosctl/loadavg_reader.rb', line 9 def avg @avg end |
#ctid ⇒ Object
Returns the value of attribute ctid
9 10 11 |
# File 'lib/libosctl/loadavg_reader.rb', line 9 def ctid @ctid end |
#pool_name ⇒ Object
Returns the value of attribute pool_name
9 10 11 |
# File 'lib/libosctl/loadavg_reader.rb', line 9 def pool_name @pool_name end |
#runnable ⇒ Object
Returns the value of attribute runnable
9 10 11 |
# File 'lib/libosctl/loadavg_reader.rb', line 9 def runnable @runnable end |
#total ⇒ Object
Returns the value of attribute total
9 10 11 |
# File 'lib/libosctl/loadavg_reader.rb', line 9 def total @total end |
Instance Method Details
#averages ⇒ Object
14 15 16 |
# File 'lib/libosctl/loadavg_reader.rb', line 14 def averages [avg[1], avg[5], avg[15]] end |
#ident ⇒ Object
10 11 12 |
# File 'lib/libosctl/loadavg_reader.rb', line 10 def ident "#{pool_name}:#{ctid}" end |