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.
-
#last_pid ⇒ Object
Returns the value of attribute last_pid.
-
#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
7 8 9 |
# File 'lib/libosctl/loadavg_reader.rb', line 7 def avg @avg end |
#ctid ⇒ Object
Returns the value of attribute ctid
7 8 9 |
# File 'lib/libosctl/loadavg_reader.rb', line 7 def ctid @ctid end |
#last_pid ⇒ Object
Returns the value of attribute last_pid
7 8 9 |
# File 'lib/libosctl/loadavg_reader.rb', line 7 def last_pid @last_pid end |
#pool_name ⇒ Object
Returns the value of attribute pool_name
7 8 9 |
# File 'lib/libosctl/loadavg_reader.rb', line 7 def pool_name @pool_name end |
#runnable ⇒ Object
Returns the value of attribute runnable
7 8 9 |
# File 'lib/libosctl/loadavg_reader.rb', line 7 def runnable @runnable end |
#total ⇒ Object
Returns the value of attribute total
7 8 9 |
# File 'lib/libosctl/loadavg_reader.rb', line 7 def total @total end |
Instance Method Details
#averages ⇒ Object
12 13 14 |
# File 'lib/libosctl/loadavg_reader.rb', line 12 def averages [avg[1], avg[5], avg[15]] end |
#ident ⇒ Object
8 9 10 |
# File 'lib/libosctl/loadavg_reader.rb', line 8 def ident "#{pool_name}:#{ctid}" end |