Class: FSR::App::BindMetaApp

Inherits:
Application show all
Defined in:
lib/fsr/app/bind_meta_app.rb

Instance Attribute Summary (collapse)

Instance Method Summary (collapse)

Methods inherited from Application

#raw, #sendmsg, #to_s

Constructor Details

- (BindMetaApp) initialize(args)

A new instance of BindMetaApp



8
9
10
# File 'lib/fsr/app/bind_meta_app.rb', line 8

def initialize(args)
  @options = args
end

Instance Attribute Details

- (Object) options (readonly)

Returns the value of attribute options



6
7
8
# File 'lib/fsr/app/bind_meta_app.rb', line 6

def options
  @options
end

Instance Method Details

- (Object) app_name

It would be better to fix App#app_name to transform CamelCase to snake_case, but that’ll be later.



14
15
16
# File 'lib/fsr/app/bind_meta_app.rb', line 14

def app_name
  "bind_meta_app"
end

- (Object) arguments



18
19
20
21
# File 'lib/fsr/app/bind_meta_app.rb', line 18

def arguments
  parameters = options[:parameters] ? "::#{options[:parameters]}" : ""
  [options[:key], options[:listen_to], options[:respond_on], options[:application] + parameters]
end