inflections.php

Go to the documentation of this file.
00001 <?php
00002 /* SVN FILE: $Id: cake_2console_2libs_2templates_2skel_2config_2inflections_8php-source.html 580 2008-07-01 14:45:49Z gwoo $ */
00003 /**
00004  * Custom Inflected Words.
00005  *
00006  * This file is used to hold words that are not matched in the normail Inflector::pluralize() and
00007  * Inflector::singularize()
00008  *
00009  * PHP versions 4 and %
00010  *
00011  * CakePHP(tm) :  Rapid Development Framework <http://www.cakephp.org/>
00012  * Copyright 2005-2008, Cake Software Foundation, Inc.
00013  *                              1785 E. Sahara Avenue, Suite 490-204
00014  *                              Las Vegas, Nevada 89104
00015  *
00016  * Licensed under The MIT License
00017  * Redistributions of files must retain the above copyright notice.
00018  *
00019  * @filesource
00020  * @copyright       Copyright 2005-2008, Cake Software Foundation, Inc.
00021  * @link                http://www.cakefoundation.org/projects/info/cakephp CakePHP(tm) Project
00022  * @package         cake
00023  * @subpackage      cake.app.config
00024  * @since           CakePHP(tm) v 1.0.0.2312
00025  * @version         $Revision: 580 $
00026  * @modifiedby      $LastChangedBy: gwoo $
00027  * @lastmodified    $Date: 2008-07-01 09:45:49 -0500 (Tue, 01 Jul 2008) $
00028  * @license         http://www.opensource.org/licenses/mit-license.php The MIT License
00029  */
00030 /**
00031  * This is a key => value array of regex used to match words.
00032  * If key matches then the value is returned.
00033  *
00034  *  $pluralRules = array('/(s)tatus$/i' => '\1\2tatuses', '/^(ox)$/i' => '\1\2en', '/([m|l])ouse$/i' => '\1ice');
00035  */
00036     $pluralRules = array();
00037 /**
00038  * This is a key only array of plural words that should not be inflected.
00039  * Notice the last comma
00040  *
00041  * $uninflectedPlural = array('.*[nrlm]ese', '.*deer', '.*fish', '.*measles', '.*ois', '.*pox');
00042  */
00043     $uninflectedPlural = array();
00044 /**
00045  * This is a key => value array of plural irregular words.
00046  * If key matches then the value is returned.
00047  *
00048  *  $irregularPlural = array('atlas' => 'atlases', 'beef' => 'beefs', 'brother' => 'brothers')
00049  */
00050     $irregularPlural = array();
00051 /**
00052  * This is a key => value array of regex used to match words.
00053  * If key matches then the value is returned.
00054  *
00055  *  $singularRules = array('/(s)tatuses$/i' => '\1\2tatus', '/(matr)ices$/i' =>'\1ix','/(vert|ind)ices$/i')
00056  */
00057     $singularRules = array();
00058 /**
00059  * This is a key only array of singular words that should not be inflected.
00060  * You should not have to change this value below if you do change it use same format
00061  * as the $uninflectedPlural above.
00062  */
00063     $uninflectedSingular = $uninflectedPlural;
00064 /**
00065  * This is a key => value array of singular irregular words.
00066  * Most of the time this will be a reverse of the above $irregularPlural array
00067  * You should not have to change this value below if you do change it use same format
00068  *
00069  * $irregularSingular = array('atlases' => 'atlas', 'beefs' => 'beef', 'brothers' => 'brother')
00070  */
00071     $irregularSingular = array_flip($irregularPlural);
00072 ?>