Sha256: c8b29305c737dac1fa08d0653995056ddeb13675f7fc21fa83be4538d9335993

Contents?: true

Size: 569 Bytes

Versions: 2

Compression:

Stored size: 569 Bytes

Contents

require 'rails/generators/resource_helpers'
require 'generators/resty/base'
module Resty
  module Generators
    class ControllerGenerator < Base
      include Rails::Generators::ResourceHelpers

      source_root File.expand_path('../../templates', __FILE__)
      
      argument :actions, :type => :array, :default => [], :banner => "action action"

      def create_controller_file
        template 'Controller.java', File.join(java_root, controllers_base_package.gsub(/\./, "/"), class_path, "#{controller_class_name}Controller.java")
      end

    end
  end
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
resty-generators-0.2.0 lib/generators/resty/controller/controller_generator.rb
resty-generators-0.1.0 lib/generators/resty/controller/controller_generator.rb