class method self.new

Ruby on Rails 3.2.22.5

Since v3.0.20 Last seen in v3.2.22.5

Available in: v3.0.20 v3.1.12 v3.2.22.5

Signature

self.new(name, type=nil, index_type=false, attr_options={})

No documentation comment.

Parameters

name req
type opt = nil
index_type opt = false
attr_options opt = {}
Source
# File railties/lib/rails/generators/generated_attribute.rb, line 40
      def initialize(name, type=nil, index_type=false, attr_options={})
        @name           = name
        @type           = (type.presence || :string).to_sym
        @has_index      = %w(index uniq).include?(index_type)
        @has_uniq_index = %w(uniq).include?(index_type)
        @attr_options   = attr_options
      end

Defined in railties/lib/rails/generators/generated_attribute.rb line 40 · View on GitHub · Improve this page · Find usages on GitHub

Defined in Rails::Generators::GeneratedAttribute

Type at least 2 characters to search.

↑↓ navigate · open · esc close