aboutsummaryrefslogtreecommitdiffstats
path: root/activesupport/lib/active_support/core_ext/module/attribute_accessors.rb
Commit message (Collapse)AuthorAgeFilesLines
* Change wording of some instances of 'opt out' [ci skip]Sharang Dashputre2019-03-121-5/+5
|
* attribute_accessors no longer uses extract_options since ↵Akira Matsuda2018-10-201-2/+0
| | | | a5b0c60714e1e8d8c182af830a26e1c7c884271d
* Remove unused `require "active_support/core_ext/regexp"`Ryuta Kamizono2018-07-291-1/+0
| | | | | | | | Ruby 2.4 has native `Regexp#match?`. https://ruby-doc.org/core-2.4.0/Regexp.html#method-i-match-3F Related #32034.
* Inclusive Language in Documentation Examples [ci skip]Cassidy Kobewka2018-04-151-2/+2
|
* [Active Support] require_relative => requireAkira Matsuda2017-10-211-2/+2
| | | | This basically reverts 8da30ad6be34339124ba4cb4e36aea260dda12bc
* [Active Support] `rubocop -a --only Layout/EmptyLineAfterMagicComment`Koichi ITO2017-07-111-0/+1
|
* Use frozen-string-literal in ActiveSupportKir Shatrov2017-07-091-0/+1
|
* [Active Support] require => require_relativeAkira Matsuda2017-07-011-2/+2
|
* Implement mattr_acessor :default optionGenadi Samokovarov2017-06-031-24/+19
|
* Reword according to feedbackTomer Brisker2016-09-151-8/+7
|
* Clarify that mattr_* creates public methodsTomer Brisker2016-09-131-0/+6
|
* applies new string literal convention in activesupport/libXavier Noria2016-08-061-2/+2
| | | | | The current code base is not uniform. After some discussion, we have chosen to go with double quotes by default.
* systematic revision of =~ usage in ASXavier Noria2016-07-221-2/+3
| | | | | Where appropriate prefer the more concise Regexp#match?, String#include?, String#start_with?, and String#end_with?
* fixed spelling in the attribute_accessors docuTorsten Braun2016-03-231-1/+1
| | | mattr_writer to mattr_reader
* fixed spellin in the mattr_reader documentationTorsten Braun2016-03-231-1/+1
| | | renamed cattr_reader to mattr_reader
* Fix documentation for mattr_accessor methodsJan Habermann2015-12-201-6/+6
|
* Minor fix in Module#mattr_reader documentationYuri Kasperovich2015-11-091-1/+1
|
* Regex fix for mattr_accessor validationAliaksandr Buhayeu2015-10-011-2/+2
| | | | | Change ^ and $ operators to \A and \z to prevent code injection after the line breaks
* Correcting `NameError` error message in `mattr_reader` method. Since this ↵amitkumarsuroliya2015-09-191-2/+2
| | | | | | commit https://github.com/rails/rails/commit/7dfbd91b0780fbd6a1dd9bfbc176e10894871d2d, `NameError` includes attribute_name also in error message [ci skip]
* Only invoke the default block for mattr_accessor once so that it does not ↵Lachlan Sylvester2015-08-071-1/+1
| | | | cause issues if it is not idempotent
* Replace `#=>` with `# =>` [ci skip]claudiob2014-12-171-1/+1
| | | | | | | | @rafaelfranca suggested in f7c7bcd9 that code examples should display the result after `# =>` and not after `#=>`. This commit replaces *all* the occurrences of `#=>` in the code documentation (mostly added by me :sob:) with the suggested `# =>`.
* Spelling and Grammar check [ci skip]Akshay Vishnoi2013-12-161-2/+2
|
* Unify cattr and mattr accessors declarationsGenadi Samokovarov2013-12-021-14/+160
|
* fix example format and add markup in Module#mattr_accessor documentation [ci ↵Francesco Rodriguez2012-05-291-10/+10
| | | | skip]
* update Module#mattr_accessor documentation [ci skip]Francesco Rodriguez2012-05-261-6/+6
|
* String quotes and trailing spacesAlexey Gaziev2012-04-291-2/+2
|
* validate attribute names in class and module attribute accessorsDmitry Plashchynski2012-03-301-0/+2
|
* Added instance_accessor: false to Module#mattr_accessorVijay Dev2011-06-141-2/+6
|
* Deletes trailing whitespaces (over text files only find * -type f -exec sed ↵Santiago Pastorino2010-08-141-1/+1
| | | | 's/[ \t]*$//' -i {} \;)
* It's not needed to initialize the attr when calling mattr_writerSantiago Pastorino2010-07-181-7/+1
|
* LINE on class_eval need + 1, also removed comments [#4281 state:committed]Santiago Pastorino2010-03-271-20/+20
| | | | Signed-off-by: José Valim <jose.valim@gmail.com>
* fixing inconsistency with cattr_reader and matter_reader [#4172 state:resolved]Kabari Hendrick2010-03-271-5/+9
| | | Signed-off-by: wycats <wycats@gmail.com>
* Merge branch 'master' into cherryJeremy Kemper2009-04-201-2/+2
|\ | | | | | | | | | | | | | | | | | | | | Conflicts: activesupport/CHANGELOG activesupport/lib/active_support/core_ext/class/delegating_attributes.rb activesupport/lib/active_support/core_ext/hash/conversions.rb activesupport/lib/active_support/core_ext/module/attribute_accessors.rb activesupport/lib/active_support/core_ext/string/multibyte.rb activesupport/lib/active_support/core_ext/time/calculations.rb activesupport/lib/active_support/deprecation.rb
| * Sync with rails/rails/master, merge two metaprogramming annotation effortsMichael S. Klishin2008-12-281-24/+24
| |\
| * | Annotated metaprogramming code across ActiveSupportMichael S. Klishin2008-12-281-23/+23
| | |
* | | Explicit dependency on Array#extract_options!Jeremy Kemper2009-03-241-24/+28
| |/ |/|
* | Inline code comments for class_eval/module_eval [#1657 state:resolved]Xavier Noria2008-12-281-24/+24
|/ | | | Signed-off-by: Pratik Naik <pratiknaik@gmail.com>
* Improve documentation coverage and markupXavier Noria2008-05-021-1/+11
| | | | Signed-off-by: Pratik Naik <pratiknaik@gmail.com>
* Refactored in use of extract_options! (closes #9079) [josh]David Heinemeier Hansson2007-07-241-1/+1
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@7220 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Added :instance_writer option to #mattr_writer/accessor, ↵Rick Olson2007-01-281-1/+5
| | | | | | #cattr_writer/accessor, and #class_inheritable_writer to skip the creation of the instance writer. [Rick] git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@6050 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Added reusable reloading support through the inclusion of the Relodable ↵David Heinemeier Hansson2006-01-291-0/+44
module that all subclasses of ActiveRecord::Base, ActiveRecord::Observer, ActiveController::Base, and ActionMailer::Base automatically gets [DHH]. Added auto-loading support for classes in modules, so Conductor::Migration will look for conductor/migration.rb and Conductor::Database::Settings will look for conductor/database/settings.rb [Nicholas Seckar]. Refactored extensions to module, class, and object in active support [DHH] git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@3493 5ecf4fe2-1ee6-0310-87b1-e25e094e27de