Add @link to global functions

This commit is contained in:
Kyle Robinson Young 2011-11-26 14:42:37 -08:00
parent fb3d3ca943
commit 1d843f84b9

View file

@ -126,6 +126,7 @@ if (!function_exists('sortByKey')) {
* @param string $order Sort order asc/desc (ascending or descending). * @param string $order Sort order asc/desc (ascending or descending).
* @param integer $type Type of sorting to perform * @param integer $type Type of sorting to perform
* @return mixed Sorted array * @return mixed Sorted array
* @link http://book.cakephp.org/2.0/en/core-libraries/global-constants-and-functions.html#sortByKey
*/ */
function sortByKey(&$array, $sortby, $order = 'asc', $type = SORT_NUMERIC) { function sortByKey(&$array, $sortby, $order = 'asc', $type = SORT_NUMERIC) {
if (!is_array($array)) { if (!is_array($array)) {
@ -198,6 +199,7 @@ function h($text, $double = true, $charset = null) {
* @param boolean $dotAppend Set to true if you want the plugin to have a '.' appended to it. * @param boolean $dotAppend Set to true if you want the plugin to have a '.' appended to it.
* @param string $plugin Optional default plugin to use if no plugin is found. Defaults to null. * @param string $plugin Optional default plugin to use if no plugin is found. Defaults to null.
* @return array Array with 2 indexes. 0 => plugin name, 1 => classname * @return array Array with 2 indexes. 0 => plugin name, 1 => classname
* @link http://book.cakephp.org/2.0/en/core-libraries/global-constants-and-functions.html#pluginSplit
*/ */
function pluginSplit($name, $dotAppend = false, $plugin = null) { function pluginSplit($name, $dotAppend = false, $plugin = null) {
if (strpos($name, '.') !== false) { if (strpos($name, '.') !== false) {
@ -521,6 +523,7 @@ function __($singular, $args = null) {
* @param integer $count Count * @param integer $count Count
* @param mixed $args Array with arguments or multiple arguments in function * @param mixed $args Array with arguments or multiple arguments in function
* @return mixed plural form of translated string * @return mixed plural form of translated string
* @link http://book.cakephp.org/2.0/en/core-libraries/global-constants-and-functions.html#__n
*/ */
function __n($singular, $plural, $count, $args = null) { function __n($singular, $plural, $count, $args = null) {
if (!$singular) { if (!$singular) {
@ -544,6 +547,7 @@ function __n($singular, $plural, $count, $args = null) {
* @param string $msg String to translate * @param string $msg String to translate
* @param mixed $args Array with arguments or multiple arguments in function * @param mixed $args Array with arguments or multiple arguments in function
* @return translated string * @return translated string
* @link http://book.cakephp.org/2.0/en/core-libraries/global-constants-and-functions.html#__d
*/ */
function __d($domain, $msg, $args = null) { function __d($domain, $msg, $args = null) {
if (!$msg) { if (!$msg) {
@ -570,6 +574,7 @@ function __d($domain, $msg, $args = null) {
* @param integer $count Count * @param integer $count Count
* @param mixed $args Array with arguments or multiple arguments in function * @param mixed $args Array with arguments or multiple arguments in function
* @return plural form of translated string * @return plural form of translated string
* @link http://book.cakephp.org/2.0/en/core-libraries/global-constants-and-functions.html#__dn
*/ */
function __dn($domain, $singular, $plural, $count, $args = null) { function __dn($domain, $singular, $plural, $count, $args = null) {
if (!$singular) { if (!$singular) {
@ -607,6 +612,7 @@ function __dn($domain, $singular, $plural, $count, $args = null) {
* @param integer $category Category * @param integer $category Category
* @param mixed $args Array with arguments or multiple arguments in function * @param mixed $args Array with arguments or multiple arguments in function
* @return translated string * @return translated string
* @link http://book.cakephp.org/2.0/en/core-libraries/global-constants-and-functions.html#__dc
*/ */
function __dc($domain, $msg, $category, $args = null) { function __dc($domain, $msg, $category, $args = null) {
if (!$msg) { if (!$msg) {
@ -648,6 +654,7 @@ function __dc($domain, $msg, $category, $args = null) {
* @param integer $category Category * @param integer $category Category
* @param mixed $args Array with arguments or multiple arguments in function * @param mixed $args Array with arguments or multiple arguments in function
* @return plural form of translated string * @return plural form of translated string
* @link http://book.cakephp.org/2.0/en/core-libraries/global-constants-and-functions.html#__dcn
*/ */
function __dcn($domain, $singular, $plural, $count, $category, $args = null) { function __dcn($domain, $singular, $plural, $count, $category, $args = null) {
if (!$singular) { if (!$singular) {
@ -681,6 +688,7 @@ function __dcn($domain, $singular, $plural, $count, $category, $args = null) {
* @param integer $category Category * @param integer $category Category
* @param mixed $args Array with arguments or multiple arguments in function * @param mixed $args Array with arguments or multiple arguments in function
* @return translated string * @return translated string
* @link http://book.cakephp.org/2.0/en/core-libraries/global-constants-and-functions.html#__c
*/ */
function __c($msg, $category, $args = null) { function __c($msg, $category, $args = null) {
if (!$msg) { if (!$msg) {
@ -700,6 +708,8 @@ function __c($msg, $category, $args = null) {
* Shortcut to Log::write. * Shortcut to Log::write.
* *
* @param string $message Message to write to log * @param string $message Message to write to log
* @return void
* @link http://book.cakephp.org/2.0/en/core-libraries/global-constants-and-functions.html#LogError
*/ */
function LogError($message) { function LogError($message) {
App::uses('CakeLog', 'Log'); App::uses('CakeLog', 'Log');