aboutsummaryrefslogtreecommitdiffstats
path: root/activesupport/lib/active_support/inflector.rb
Commit message (Collapse)AuthorAgeFilesLines
* Improve documentation to classify to make it clear that it expects names to ↵Michael Koziarski2008-01-081-2/+5
| | | | | | be plural. Reference #10615 [kris_chambers] git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@8596 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Fixed String#titleize to work for strings with 's too (closes #10571) [trek]David Heinemeier Hansson2008-01-031-1/+1
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@8533 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Fixed that pluralizing an empty string should return the same empty string, ↵David Heinemeier Hansson2007-09-221-1/+1
| | | | | | not "s" (closes #7720) [josh] git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@7569 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Some 1.9 forward compatibilityJeremy Kemper2007-09-141-3/+3
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@7474 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Added support for pluralization with a different starting letter than the ↵David Heinemeier Hansson2007-06-231-2/+9
| | | | | | singular version (cow/kine) (closes #4929) [norri_b/hasmanyjosh] git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@7092 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Full test coverage for Inflector. Closes #7228.Jeremy Kemper2007-01-281-3/+2
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@6075 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Document Inflector.ordinalize and merge docs from String inflections. Closes ↵Jeremy Kemper2007-01-141-18/+115
| | | | | | #7023. git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@5924 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Normalize classify's argument to a String so that it plays nice with ↵Marcel Molina2006-05-221-1/+1
| | | | | | Symbols. [Marcel Molina Jr.] git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@4359 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Strip out leading schema name in classify. References #5139. ↵Marcel Molina2006-05-211-1/+2
| | | | | | [schoenm@earthlink.net] git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@4350 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Added option to String#camelize to generate lower-cased camel case by ↵David Heinemeier Hansson2006-03-201-2/+6
| | | | | | passing in :lower, like "super_man".camelize(:lower) # => "superMan" [DHH] git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@3986 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Enhance Inflector.underscore to convert '-' into '_' (as the inverse of ↵Jamis Buck2006-03-151-1/+5
| | | | | | Inflector.dasherize) git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@3877 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Added Hash#to_xml and Array#to_xml that makes it much easier to produce XML ↵David Heinemeier Hansson2006-03-081-0/+4
| | | | | | from basic structures [DHH] Moved Jim Weirich's wonderful Builder from Action Pack to Active Support (it's simply too useful to be stuck in AP) [DHH] git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@3812 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Fix constantize to handle names beginning with '::'. Closes #3803.Nicholas Seckar2006-02-111-2/+2
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@3571 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Change Inflector#constantize to use eval instead of const_getNicholas Seckar2005-11-161-3/+5
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@3049 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Add title case method to String to do, e.g., 'action_web_service'.titlecase ↵Marcel Molina2005-10-191-1/+5
| | | | | | # => 'Action Web Service'. git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@2690 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Fixed Inflector.underscore for use with acronyms, so HTML becomes html ↵David Heinemeier Hansson2005-09-131-1/+1
| | | | | | instead of htm_l #2173 [k@v2studio.com] git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@2227 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Added documentation for overwrite_params #2146 [Michael Shuerig]David Heinemeier Hansson2005-09-091-2/+1
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@2162 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Added String#at, String#from, String#to, String#first, String#last in ↵David Heinemeier Hansson2005-09-031-67/+91
| | | | | | ActiveSupport::CoreExtensions::String::Access to ease access to individual characters and substrings in a string serving basically as human names for range access. Added easy extendability to the inflector through Inflector.inflections (using the Inflector::Inflections singleton class) git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@2110 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Fixed inflections of "index/indices" #1766 [damn_pepe@gmail.com]David Heinemeier Hansson2005-07-221-2/+2
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@1881 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Added stripping of _id to String#humanize, so "employee_id" becomes ↵David Heinemeier Hansson2005-07-171-1/+1
| | | | | | "Employee" #1574 [Justin French] git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@1854 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Added Fixnum#ordinalize to turn 1.ordinalize to "1st", 3.ordinalize to ↵David Heinemeier Hansson2005-07-171-1/+14
| | | | | | "3rd", and 10.ordinalize to "10th" and so on #1724 [paul@cnt.org] git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@1852 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* More inflector fixes #1608David Heinemeier Hansson2005-07-051-30/+41
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@1699 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* More inflector fixes #1599 [foamdino@gmail.com]David Heinemeier Hansson2005-07-041-3/+6
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@1662 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* More inflectoring #1490David Heinemeier Hansson2005-07-021-0/+2
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@1616 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Fixed photo/photos #1583David Heinemeier Hansson2005-07-021-9/+11
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@1615 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Added new rules to the Inflector to deal with more unusual plurals ↵David Heinemeier Hansson2005-07-011-0/+9
| | | | | | mouse/louse => mice/lice, information => information, ox => oxen #1571 [foamdino@gmail.com] git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@1582 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Fixed the Inflector to underscore strings containing numbers, so ↵David Heinemeier Hansson2005-05-191-1/+1
| | | | | | Area51Controller becomes area51_controller #1176 [Nicholas Seckar] git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@1330 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Fixed the pluralization of analysis to analyses #1295 ↵David Heinemeier Hansson2005-05-191-0/+1
| | | | | | [seattle@rootimage.msu.edu] git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@1314 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Fixed inflection of perspectives and similar words #1045 ↵David Heinemeier Hansson2005-04-071-0/+1
| | | | | | [thijs@vandervossen.net] git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@1101 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Fixed Inflector.pluralize to handle capitalized words #932 [bitsweat]David Heinemeier Hansson2005-03-261-27/+27
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@998 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Added inflection rules for "sh" words, like "wish" and "fish" #755 ↵David Heinemeier Hansson2005-03-061-1/+3
| | | | | | [phillip@pjbsoftware.com] git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@844 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Moved Active Support into its own gemDavid Heinemeier Hansson2005-02-151-0/+93
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@624 5ecf4fe2-1ee6-0310-87b1-e25e094e27de