X-Git-Url: http://git.ithinksw.org/extjs.git/blobdiff_plain/7a654f8d43fdb43d78b63d90528bed6e86b608cc..3789b528d8dd8aad4558e38e22d775bcab1cbd36:/docs/source/Inflector.html diff --git a/docs/source/Inflector.html b/docs/source/Inflector.html index c64236fb..1e334c88 100644 --- a/docs/source/Inflector.html +++ b/docs/source/Inflector.html @@ -1,4 +1,21 @@ -
/**
+
+
+
+
+ The source code
+
+
+
+
+
+
+ /**
* @class Ext.util.Inflector
* @extends Object
* <p>General purpose inflector class that {@link #pluralize pluralizes}, {@link #singularize singularizes} and
@@ -52,7 +69,7 @@ Ext.define('Ext.util.Inflector', {
/* End Definitions */
- /**
+ /**
* @private
* The registered plural tuples. Each item in the array should contain two items - the first must be a regular
* expression that matchers the singular form of a word, the second must be a String that replaces the matched
@@ -83,7 +100,7 @@ Ext.define('Ext.util.Inflector', {
[(/$/), "s" ]
],
- /**
+ /**
* @private
* The set of registered singular matchers. Each item in the array should contain two items - the first must be a
* regular expression that matches the plural form of a word, the second must be a String that replaces the
@@ -119,7 +136,7 @@ Ext.define('Ext.util.Inflector', {
[(/s$/i), "" ]
],
- /**
+ /**
* @private
* The registered uncountable words
* @property uncountable
@@ -141,7 +158,7 @@ Ext.define('Ext.util.Inflector', {
"means"
],
- /**
+ /**
* Adds a new singularization rule to the Inflector. See the intro docs for more information
* @param {RegExp} matcher The matcher regex
* @param {String} replacer The replacement string, which can reference matches from the matcher argument
@@ -150,7 +167,7 @@ Ext.define('Ext.util.Inflector', {
this.singulars.unshift([matcher, replacer]);
},
- /**
+ /**
* Adds a new pluralization rule to the Inflector. See the intro docs for more information
* @param {RegExp} matcher The matcher regex
* @param {String} replacer The replacement string, which can reference matches from the matcher argument
@@ -159,21 +176,21 @@ Ext.define('Ext.util.Inflector', {
this.plurals.unshift([matcher, replacer]);
},
- /**
+ /**
* Removes all registered singularization rules
*/
clearSingulars: function() {
this.singulars = [];
},
- /**
+ /**
* Removes all registered pluralization rules
*/
clearPlurals: function() {
this.plurals = [];
},
- /**
+ /**
* Returns true if the given word is transnumeral (the word is its own singular and plural form - e.g. sheep, fish)
* @param {String} word The word to test
* @return {Boolean} True if the word is transnumeral
@@ -182,7 +199,7 @@ Ext.define('Ext.util.Inflector', {
return Ext.Array.indexOf(this.uncountable, word) != -1;
},
- /**
+ /**
* Returns the pluralized form of a word (e.g. Ext.util.Inflector.pluralize('word') returns 'words')
* @param {String} word The word to pluralize
* @return {String} The pluralized form of the word
@@ -208,7 +225,7 @@ Ext.define('Ext.util.Inflector', {
return word;
},
- /**
+ /**
* Returns the singularized form of a word (e.g. Ext.util.Inflector.singularize('words') returns 'word')
* @param {String} word The word to singularize
* @return {String} The singularized form of the word
@@ -234,7 +251,7 @@ Ext.define('Ext.util.Inflector', {
return word;
},
- /**
+ /**
* Returns the correct {@link Ext.data.Model Model} name for a given string. Mostly used internally by the data
* package
* @param {String} word The word to classify
@@ -244,7 +261,7 @@ Ext.define('Ext.util.Inflector', {
return Ext.String.capitalize(this.singularize(word));
},
- /**
+ /**
* Ordinalizes a given number by adding a prefix such as 'st', 'nd', 'rd' or 'th' based on the last digit of the
* number. 21 -> 21st, 22 -> 22nd, 23 -> 23rd, 24 -> 24th etc
* @param {Number} number The number to ordinalize
@@ -308,4 +325,6 @@ Ext.define('Ext.util.Inflector', {
this.plural(singular, irregulars[singular]);
this.singular(irregulars[singular], singular);
}
-});
\ No newline at end of file
+});
+
+