Class: Ship::Country

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

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(name, code) ⇒ Country

Returns a new instance of Country.



4
5
6
7
# File 'lib/country.rb', line 4

def initialize(name,code)
	@name	= name
	@code	= code
end

Instance Attribute Details

#codeObject (readonly)

Returns the value of attribute code.



3
4
5
# File 'lib/country.rb', line 3

def code
  @code
end

#nameObject (readonly)

Returns the value of attribute name.



3
4
5
# File 'lib/country.rb', line 3

def name
  @name
end