Class: AMQTapListener

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

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(activity, amq, &block) ⇒ AMQTapListener

Returns a new instance of AMQTapListener.



16
17
18
19
20
21
# File 'lib/android_motion_query/events.rb', line 16

def initialize(activity, amq, &block)
  self.activity = activity
  self.callback = block
  self.amq = amq
  self
end

Instance Attribute Details

#activityObject

Returns the value of attribute activity.



15
16
17
# File 'lib/android_motion_query/events.rb', line 15

def activity
  @activity
end

#amqObject

Returns the value of attribute amq.



15
16
17
# File 'lib/android_motion_query/events.rb', line 15

def amq
  @amq
end

#callbackObject

Returns the value of attribute callback.



15
16
17
# File 'lib/android_motion_query/events.rb', line 15

def callback
  @callback
end

Instance Method Details

#onClick(view) ⇒ Object



23
24
25
# File 'lib/android_motion_query/events.rb', line 23

def onClick(view)
  self.callback.call(view)
end