Class: IceGrid::LoadInfo
- Inherits:
-
Object
- Object
- IceGrid::LoadInfo
- Includes:
- Ice::Inspect_mixin
- Defined in:
- lib/IceGrid/Admin.rb
Instance Attribute Summary collapse
-
#avg1 ⇒ Object
Returns the value of attribute avg1.
-
#avg15 ⇒ Object
Returns the value of attribute avg15.
-
#avg5 ⇒ Object
Returns the value of attribute avg5.
Instance Method Summary collapse
- #==(other) ⇒ Object
- #eql?(other) ⇒ Boolean
- #hash ⇒ Object
-
#initialize(avg1 = 0.0, avg5 = 0.0, avg15 = 0.0) ⇒ LoadInfo
constructor
A new instance of LoadInfo.
Methods included from Ice::Inspect_mixin
Constructor Details
#initialize(avg1 = 0.0, avg5 = 0.0, avg15 = 0.0) ⇒ LoadInfo
Returns a new instance of LoadInfo.
320 321 322 323 324 |
# File 'lib/IceGrid/Admin.rb', line 320 def initialize(avg1=0.0, avg5=0.0, avg15=0.0) @avg1 = avg1 @avg5 = avg5 @avg15 = avg15 end |
Instance Attribute Details
#avg1 ⇒ Object
Returns the value of attribute avg1.
346 347 348 |
# File 'lib/IceGrid/Admin.rb', line 346 def avg1 @avg1 end |
#avg15 ⇒ Object
Returns the value of attribute avg15.
346 347 348 |
# File 'lib/IceGrid/Admin.rb', line 346 def avg15 @avg15 end |
#avg5 ⇒ Object
Returns the value of attribute avg5.
346 347 348 |
# File 'lib/IceGrid/Admin.rb', line 346 def avg5 @avg5 end |
Instance Method Details
#==(other) ⇒ Object
334 335 336 337 338 339 340 |
# File 'lib/IceGrid/Admin.rb', line 334 def ==(other) return false if !other.is_a? ::IceGrid::LoadInfo or @avg1 != other.avg1 or @avg5 != other.avg5 or @avg15 != other.avg15 true end |
#eql?(other) ⇒ Boolean
342 343 344 |
# File 'lib/IceGrid/Admin.rb', line 342 def eql?(other) return other.class == self.class && other == self end |
#hash ⇒ Object
326 327 328 329 330 331 332 |
# File 'lib/IceGrid/Admin.rb', line 326 def hash _h = 0 _h = 5 * _h + @avg1.hash _h = 5 * _h + @avg5.hash _h = 5 * _h + @avg15.hash _h % 0x7fffffff end |