Class: Celluloid::Proxy::AbstractCall

Inherits:
Abstract
  • Object
show all
Defined in:
lib/celluloid/proxy/abstract.rb

Direct Known Subclasses

Async, Future, Sync

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods inherited from Abstract

#__class__

Constructor Details

#initialize(mailbox, klass) ⇒ AbstractCall

Returns a new instance of AbstractCall.



30
31
32
33
# File 'lib/celluloid/proxy/abstract.rb', line 30

def initialize(mailbox, klass)
  @mailbox = mailbox
  @klass = klass
end

Instance Attribute Details

#mailboxObject (readonly)

Returns the value of attribute mailbox.



28
29
30
# File 'lib/celluloid/proxy/abstract.rb', line 28

def mailbox
  @mailbox
end

Instance Method Details

#__klass__Object



43
44
45
# File 'lib/celluloid/proxy/abstract.rb', line 43

def __klass__
  @klass
end

#eql?(other) ⇒ Boolean

Returns:

  • (Boolean)


35
36
37
# File 'lib/celluloid/proxy/abstract.rb', line 35

def eql?(other)
  __class__.eql?(::Celluloid::Proxy.class_of(other)) && @mailbox.eql?(other.mailbox)
end

#hashObject



39
40
41
# File 'lib/celluloid/proxy/abstract.rb', line 39

def hash
  @mailbox.hash
end

#inspectObject



47
48
49
# File 'lib/celluloid/proxy/abstract.rb', line 47

def inspect
  "#<#{__class__}(#{@klass})>"
end