Class: RubyHome::HTTP::Application
- Inherits:
-
Object
- Object
- RubyHome::HTTP::Application
- Defined in:
- lib/ruby_home/http/application.rb
Class Method Summary collapse
Class Method Details
.rack_builder ⇒ Object
14 15 16 17 18 19 20 21 22 23 |
# File 'lib/ruby_home/http/application.rb', line 14 def rack_builder ::Rack::Builder.new do map('/accessories') { run AccessoriesController } map('/characteristics') { run CharacteristicsController } map('/identify') { run IdentifyController } map('/pair-setup') { run PairSetupsController } map('/pair-verify') { run PairVerifiesController } map('/pairings') { run PairingsController } end end |
.run ⇒ Object
7 8 9 10 11 12 |
# File 'lib/ruby_home/http/application.rb', line 7 def run ::Rack::Handler::WEBrick.new( ::WEBrick::HTTPServer.new(DoNotListen: true), rack_builder ) end |