Class: Ice::ACM
- Inherits:
-
Object
- Object
- Ice::ACM
- Defined in:
- lib/Ice/Connection.rb
Instance Attribute Summary collapse
-
#close ⇒ Object
Returns the value of attribute close.
-
#heartbeat ⇒ Object
Returns the value of attribute heartbeat.
-
#timeout ⇒ Object
Returns the value of attribute timeout.
Instance Method Summary collapse
- #==(other) ⇒ Object
- #eql?(other) ⇒ Boolean
- #hash ⇒ Object
-
#initialize(timeout = 0, close = ::Ice::ACMClose::CloseOff, heartbeat = ::Ice::ACMHeartbeat::HeartbeatOff) ⇒ ACM
constructor
A new instance of ACM.
- #inspect ⇒ Object
Constructor Details
#initialize(timeout = 0, close = ::Ice::ACMClose::CloseOff, heartbeat = ::Ice::ACMHeartbeat::HeartbeatOff) ⇒ ACM
Returns a new instance of ACM.
214 215 216 217 218 |
# File 'lib/Ice/Connection.rb', line 214 def initialize(timeout=0, close=::Ice::ACMClose::CloseOff, heartbeat=::Ice::ACMHeartbeat::HeartbeatOff) @timeout = timeout @close = close @heartbeat = heartbeat end |
Instance Attribute Details
#close ⇒ Object
Returns the value of attribute close.
244 245 246 |
# File 'lib/Ice/Connection.rb', line 244 def close @close end |
#heartbeat ⇒ Object
Returns the value of attribute heartbeat.
244 245 246 |
# File 'lib/Ice/Connection.rb', line 244 def heartbeat @heartbeat end |
#timeout ⇒ Object
Returns the value of attribute timeout.
244 245 246 |
# File 'lib/Ice/Connection.rb', line 244 def timeout @timeout end |
Instance Method Details
#==(other) ⇒ Object
228 229 230 231 232 233 234 |
# File 'lib/Ice/Connection.rb', line 228 def ==(other) return false if !other.is_a? ::Ice::ACM or @timeout != other.timeout or @close != other.close or @heartbeat != other.heartbeat true end |
#eql?(other) ⇒ Boolean
236 237 238 |
# File 'lib/Ice/Connection.rb', line 236 def eql?(other) return other.class == self.class && other == self end |
#hash ⇒ Object
220 221 222 223 224 225 226 |
# File 'lib/Ice/Connection.rb', line 220 def hash _h = 0 _h = 5 * _h + @timeout.hash _h = 5 * _h + @close.hash _h = 5 * _h + @heartbeat.hash _h % 0x7fffffff end |