Class: App::MenuItem

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

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(command, hint = nil, selected = false) ⇒ MenuItem

Returns a new instance of MenuItem.



97
98
99
100
101
102
# File 'lib/app/menu.rb', line 97

def initialize(command, hint = nil, selected = false)
  super()
  @command = command
  @hint = hint
  @selected = selected
end

Instance Attribute Details

#commandObject (readonly)

Returns the value of attribute command.



93
94
95
# File 'lib/app/menu.rb', line 93

def command
  @command
end

#hintObject (readonly)

Returns the value of attribute hint.



94
95
96
# File 'lib/app/menu.rb', line 94

def hint
  @hint
end

#selectedObject

Returns the value of attribute selected.



95
96
97
# File 'lib/app/menu.rb', line 95

def selected
  @selected
end