Class: WFA::Console

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

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(app, http) ⇒ Console

Returns a new instance of Console.



7
8
9
10
11
12
13
14
# File 'lib/wfa/console.rb', line 7

def initialize app, http
  @wfa = app
  @http = http
  prompt = $PROGRAM_NAME.split('/').last + "> "
  binding.pry quiet: true,
    prompt:[->(a,b,c){ prompt }],
    print:->(io, *ps){ ps.each {|p|PP.pp p, io, 100 } }
end

Instance Attribute Details

#httpObject (readonly)

Returns the value of attribute http.



6
7
8
# File 'lib/wfa/console.rb', line 6

def http
  @http
end

#wfaObject (readonly)

Returns the value of attribute wfa.



6
7
8
# File 'lib/wfa/console.rb', line 6

def wfa
  @wfa
end