Class: Mac::EventMonitor::Location
- Inherits:
-
Object
- Object
- Mac::EventMonitor::Location
- Includes:
- JsonSerializable
- Defined in:
- lib/mac-event-monitor/location.rb
Instance Attribute Summary collapse
-
#x ⇒ Object
Returns the value of attribute x.
-
#y ⇒ Object
Returns the value of attribute y.
Instance Method Summary collapse
- #data ⇒ Object
-
#initialize(x, y) ⇒ Location
constructor
A new instance of Location.
Methods included from JsonSerializable
Constructor Details
#initialize(x, y) ⇒ Location
Returns a new instance of Location.
8 9 10 11 |
# File 'lib/mac-event-monitor/location.rb', line 8 def initialize(x, y) @x = x @y = y end |
Instance Attribute Details
#x ⇒ Object
Returns the value of attribute x.
6 7 8 |
# File 'lib/mac-event-monitor/location.rb', line 6 def x @x end |
#y ⇒ Object
Returns the value of attribute y.
6 7 8 |
# File 'lib/mac-event-monitor/location.rb', line 6 def y @y end |
Instance Method Details
#data ⇒ Object
13 14 15 |
# File 'lib/mac-event-monitor/location.rb', line 13 def data [x, y] end |