Class: Rack::ActorMap

Inherits:
Object
  • Object
show all
Defined in:
lib/ara/remote.rb

Instance Method Summary collapse

Constructor Details

#initialize(actor) ⇒ ActorMap

Returns a new instance of ActorMap.



6
7
8
# File 'lib/ara/remote.rb', line 6

def initialize(actor)
   @actor = actor.start
end

Instance Method Details

#call(env) ⇒ Object



10
11
12
13
14
15
16
# File 'lib/ara/remote.rb', line 10

def call( env )
 response = Rack::Response.new
 request = Rack::Request.new(env)
 message = request.params["message"]
 response.write @actor << message
 response.finish
end