Class: Robotoy::Services::Report
- Inherits:
-
Object
- Object
- Robotoy::Services::Report
- Defined in:
- lib/robotoy/services/report.rb
Instance Method Summary collapse
-
#initialize(robot:) ⇒ Report
constructor
A new instance of Report.
- #perform(type: :string) ⇒ Object
Constructor Details
#initialize(robot:) ⇒ Report
Returns a new instance of Report.
4 5 6 |
# File 'lib/robotoy/services/report.rb', line 4 def initialize(robot:) @robot = robot end |
Instance Method Details
#perform(type: :string) ⇒ Object
8 9 10 11 |
# File 'lib/robotoy/services/report.rb', line 8 def perform(type: :string) @robot.validate_if_placed send(type) end |