Class: Action

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

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(id, method_name, method, opt = {}) ⇒ Action

Returns a new instance of Action.



4
5
6
7
8
9
10
# File 'lib/vimamsa/actions.rb', line 4

def initialize(id, method_name, method, opt = {})
  @method_name = method_name
  @id = id
  @method = method
  @opt = opt
  vma.actions.register(id, self) # TODO: handle this in Editor class
end

Instance Attribute Details

#idObject

Returns the value of attribute id.



2
3
4
# File 'lib/vimamsa/actions.rb', line 2

def id
  @id
end

#methodObject

Returns the value of attribute method.



2
3
4
# File 'lib/vimamsa/actions.rb', line 2

def method
  @method
end

#method_nameObject

Returns the value of attribute method_name.



2
3
4
# File 'lib/vimamsa/actions.rb', line 2

def method_name
  @method_name
end

#optObject

Returns the value of attribute opt.



2
3
4
# File 'lib/vimamsa/actions.rb', line 2

def opt
  @opt
end