Class: FSR::App::UuidGetVar
- Inherits:
-
Application
- Object
- Application
- FSR::App::UuidGetVar
- Defined in:
- lib/fsr/app/uuid_getvar.rb
Constant Summary collapse
- SENDMSG_METHOD =
%q| def uuid_getvar(*args, &block) me = super(*args) @uuid_var = me.var api_call = "api uuid_getvar #{me.uuid} #{me.var}\n\n" send_data(api_call) @queue.unshift block if block_given? end |
Instance Attribute Summary collapse
-
#uuid ⇒ Object
readonly
Returns the value of attribute uuid.
-
#var ⇒ Object
readonly
Returns the value of attribute var.
Instance Method Summary collapse
- #arguments ⇒ Object
-
#initialize(uuid, var) ⇒ UuidGetVar
constructor
A new instance of UuidGetVar.
- #sendmsg ⇒ Object
Methods inherited from Application
Constructor Details
#initialize(uuid, var) ⇒ UuidGetVar
Returns a new instance of UuidGetVar.
8 9 10 11 |
# File 'lib/fsr/app/uuid_getvar.rb', line 8 def initialize(uuid, var) @uuid = uuid # Unique channel ID @var = var # Channel variable you wish to 'set' end |
Instance Attribute Details
#uuid ⇒ Object (readonly)
Returns the value of attribute uuid.
6 7 8 |
# File 'lib/fsr/app/uuid_getvar.rb', line 6 def uuid @uuid end |
#var ⇒ Object (readonly)
Returns the value of attribute var.
6 7 8 |
# File 'lib/fsr/app/uuid_getvar.rb', line 6 def var @var end |
Instance Method Details
#arguments ⇒ Object
13 14 15 |
# File 'lib/fsr/app/uuid_getvar.rb', line 13 def arguments [@uuid, @var] end |
#sendmsg ⇒ Object
17 18 19 |
# File 'lib/fsr/app/uuid_getvar.rb', line 17 def sendmsg "call-command: execute\nexecute-app-name: %s\nexecute-app-arg: %s\nevent-lock:true\n\n" % [app_name, arguments.join(" ")] end |