Class: PLA::Ship
- Inherits:
-
Object
- Object
- PLA::Ship
- Defined in:
- lib/pla/ship.rb
Instance Method Summary collapse
-
#initialize(ship) ⇒ Ship
constructor
A new instance of Ship.
- #to_h ⇒ Object
Constructor Details
#initialize(ship) ⇒ Ship
3 4 5 |
# File 'lib/pla/ship.rb', line 3 def initialize ship @name = ship end |
Instance Method Details
#to_h ⇒ Object
7 8 9 10 11 12 |
# File 'lib/pla/ship.rb', line 7 def to_h { name: @name, google: "https://www.google.co.uk/search?q=site:vesselfinder.com #{@name}" } end |