Class: Kawaii::Routing::Services::GenerateResourceActions

Inherits:
Object
  • Object
show all
Defined in:
lib/kawaii/routing/services/generate_resource_actions.rb

Direct Known Subclasses

GenerateResourcesActions

Instance Method Summary collapse

Constructor Details

#initialize(name, path, methods) ⇒ GenerateResourceActions

Returns a new instance of GenerateResourceActions.



5
6
7
8
9
# File 'lib/kawaii/routing/services/generate_resource_actions.rb', line 5

def initialize(name, path, methods)
  @name    = name.to_s
  @methods = methods
  @path    = path
end

Instance Method Details

#callObject



11
12
13
14
15
# File 'lib/kawaii/routing/services/generate_resource_actions.rb', line 11

def call
  methods.map do |method|
    send(method)
  end
end