Class: MClientAgent

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

Class Method Summary collapse

Class Method Details

.run(host, port, &b) ⇒ Object


363
364
365
366
367
368
369
# File 'lib/minitcp.rb', line 363

def self.run(host,port,&b) 
  me=MClientAgent.new
 MClient.run_continious(host,port,10_000) do |so|
    so.extend(SocketMessage)
    me.instance_eval { b.call(so) }
 end
end