descendants

descendants(klass) Class Public methods

serialize

serialize(name, value) Instance Protected methods

_parse_file

_parse_file(file, entity) Instance Protected methods

eql?

eql?(other) Instance Public methods Equivalent to String#eql?. Returns true if the class name and other have the same length and content, otherwise false. class BlogPost extend ActiveModel::Naming end BlogPost.model_name.eql?('BlogPost') # => true BlogPost.model_name.eql?('Blog Post') # => false

to_ary

to_ary() Instance Public methods Alias for: to_a

attr_internal_reader

attr_internal_reader(*attrs) Instance Public methods Declares an attribute reader backed by an internally-named instance variable.

parent_name

parent_name() Instance Public methods Returns the name of the module containing this one. M::N.parent_name # => "M"

button

button(value = nil, options = {}, &block) Instance Public methods Add the submit button for the given form. When no value is given, it checks if the object is a new resource or not to create the proper label: <%= form_for @post do |f| %> <%= f.button %> <% end %> In the example above, if @post is a new record, it will use âCreate Postâ as button label, otherwise, it uses âUpdate Postâ. Those labels can be customized using I18n, under the helpers.submit key (

behavior=

behavior=(behavior) Instance Public methods Sets the behavior to the specified value. Can be a single value, array, or an object that responds to call. Available behaviors: raise Raise ActiveSupport::DeprecationException. stderr Log all deprecation warnings to +$stderr+. log Log all deprecation warnings to Rails.logger. notify Use ActiveSupport::Notifications to notify deprecation.rails. silence Do nothing. Setting behaviors only affects deprecations that happ

new

new(env) Class Public methods