Class: Squidward::Command::Help::HelpGroup

Inherits:
Array
  • Object
show all
Defined in:
lib/squidward/commands/help.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(title) ⇒ HelpGroup

Returns a new instance of HelpGroup.



7
8
9
# File 'lib/squidward/commands/help.rb', line 7

def initialize(title)
  @title = title
end

Instance Attribute Details

#titleObject (readonly)

Returns the value of attribute title.



5
6
7
# File 'lib/squidward/commands/help.rb', line 5

def title
  @title
end

Instance Method Details

#command(name, description) ⇒ Object



11
12
13
# File 'lib/squidward/commands/help.rb', line 11

def command(name, description)
  self << [name, description]
end

#spaceObject



15
16
17
# File 'lib/squidward/commands/help.rb', line 15

def space
  self << ['', '']
end