More API docblock CS fixes.

This commit is contained in:
ADmad 2014-06-02 18:27:11 +05:30
parent 3108217d73
commit e7debd8692
16 changed files with 41 additions and 45 deletions

View file

@ -26,7 +26,7 @@ interface ConfigReaderInterface {
* These sources can either be static resources like files, or dynamic ones like
* a database, or other datasource.
*
* @param string $key
* @param string $key Key to read.
* @return array An array of data to merge into the runtime configuration
*/
public function read($key);

View file

@ -181,7 +181,7 @@ class IniReader implements ConfigReaderInterface {
/**
* Converts a value into the ini equivalent
*
* @param mixed $value to export.
* @param mixed $val Value to export.
* @return string String value for ini file.
*/
protected function _value($val) {

View file

@ -393,7 +393,7 @@ class App {
*
* `App::core('Cache/Engine'); will return the full path to the cache engines package`
*
* @param string $type
* @param string $type Package type.
* @return array full path to package
* @link http://book.cakephp.org/2.0/en/core-utility-libraries/app.html#App::core
*/
@ -587,19 +587,19 @@ class App {
* Finds classes based on $name or specific file(s) to search. Calling App::import() will
* not construct any classes contained in the files. It will only find and require() the file.
*
* @link http://book.cakephp.org/2.0/en/core-utility-libraries/app.html#including-files-with-app-import
* @param string|array $type The type of Class if passed as a string, or all params can be passed as
* an single array to $type,
* an single array to $type.
* @param string $name Name of the Class or a unique name for the file
* @param boolean|array $parent boolean true if Class Parent should be searched, accepts key => value
* array('parent' => $parent, 'file' => $file, 'search' => $search, 'ext' => '$ext');
* $ext allows setting the extension of the file name
* based on Inflector::underscore($name) . ".$ext";
* array('parent' => $parent, 'file' => $file, 'search' => $search, 'ext' => '$ext');
* $ext allows setting the extension of the file name
* based on Inflector::underscore($name) . ".$ext";
* @param array $search paths to search for files, array('path 1', 'path 2', 'path 3');
* @param string $file full name of the file to search for including extension
* @param boolean $return Return the loaded file, the file must have a return
* statement in it to work: return $variable;
* statement in it to work: return $variable;
* @return boolean true if Class is already in memory or if file is found and loaded, false if not
* @link http://book.cakephp.org/2.0/en/core-utility-libraries/app.html#including-files-with-app-import
*/
public static function import($type = null, $name = null, $parent = true, $search = array(), $file = null, $return = false) {
$ext = null;

View file

@ -115,7 +115,7 @@ class CakePlugin {
* The above example will load the bootstrap file for all plugins, but for DebugKit it will only load
* the routes file and will not look for any bootstrap script.
*
* @param array $options
* @param array $options Options list. See CakePlugin::load() for valid options.
* @return void
*/
public static function loadAll($options = array()) {
@ -206,7 +206,7 @@ class CakePlugin {
* Returns true if the plugin $plugin is already loaded
* If plugin is null, it will return a list of all loaded plugins
*
* @param string $plugin
* @param string $plugin Plugin name to check.
* @return mixed boolean true if $plugin is already loaded.
* If $plugin is null, returns a list of plugins that have been loaded
*/

View file

@ -62,7 +62,7 @@ class Configure {
* - Include app/Config/bootstrap.php.
* - Setup error/exception handlers.
*
* @param boolean $boot
* @param boolean $boot Whether to do bootstrapping.
* @return void
*/
public static function bootstrap($boot = true) {
@ -113,6 +113,7 @@ class Configure {
/**
* Set app's default configs
*
* @return void
*/
protected static function _appDefaults() {
@ -143,11 +144,11 @@ class Configure {
* ));
* }}}
*
* @link http://book.cakephp.org/2.0/en/development/configuration.html#Configure::write
* @param string|array $config The key to write, can be a dot notation value.
* Alternatively can be an array containing key(s) and value(s).
* @param mixed $value Value to set for var
* @return boolean True if write was successful
* @link http://book.cakephp.org/2.0/en/development/configuration.html#Configure::write
*/
public static function write($config, $value = null) {
if (!is_array($config)) {
@ -178,9 +179,9 @@ class Configure {
* Configure::read('Name.key'); will return only the value of Configure::Name[key]
* }}}
*
* @link http://book.cakephp.org/2.0/en/development/configuration.html#Configure::read
* @param string $var Variable to obtain. Use '.' to access array elements.
* @return mixed value stored in configure, or null.
* @link http://book.cakephp.org/2.0/en/development/configuration.html#Configure::read
*/
public static function read($var = null) {
if ($var === null) {
@ -211,9 +212,9 @@ class Configure {
* Configure::delete('Name.key'); will delete only the Configure::Name[key]
* }}}
*
* @link http://book.cakephp.org/2.0/en/development/configuration.html#Configure::delete
* @param string $var the var to be deleted
* @return void
* @link http://book.cakephp.org/2.0/en/development/configuration.html#Configure::delete
*/
public static function delete($var = null) {
self::$_values = Hash::remove(self::$_values, $var);
@ -240,7 +241,7 @@ class Configure {
/**
* Gets the names of the configured reader objects.
*
* @param string $name
* @param string $name Name to check. If null returns all configured reader names.
* @return array Array of the configured reader objects.
*/
public static function configured($name = null) {
@ -283,12 +284,12 @@ class Configure {
* If using `default` config and no reader has been configured for it yet,
* one will be automatically created using PhpReader
*
* @link http://book.cakephp.org/2.0/en/development/configuration.html#Configure::load
* @param string $key name of configuration resource to load.
* @param string $config Name of the configured reader to use to read the resource identified by $key.
* @param boolean $merge if config files should be merged instead of simply overridden
* @return boolean False if file not found, true if load successful.
* @throws ConfigureException Will throw any exceptions the reader raises.
* @link http://book.cakephp.org/2.0/en/development/configuration.html#Configure::load
*/
public static function load($key, $config = 'default', $merge = true) {
$reader = self::_getReader($config);

View file

@ -1,7 +1,5 @@
<?php
/**
*
*
* CakePHP(tm) : Rapid Development Framework (http://cakephp.org)
* Copyright (c) Cake Software Foundation, Inc. (http://cakefoundation.org)
*
@ -84,7 +82,7 @@ class CakeEvent {
/**
* Dynamically returns the name and subject if accessed directly
*
* @param string $attribute
* @param string $attribute Attribute name.
* @return mixed
*/
public function __get($attribute) {

View file

@ -1,7 +1,5 @@
<?php
/**
*
*
* CakePHP(tm) : Rapid Development Framework (http://cakephp.org)
* Copyright (c) Cake Software Foundation, Inc. (http://cakefoundation.org)
*
@ -64,7 +62,7 @@ class CakeEventManager {
*
* If called with the first parameter, it will be set as the globally available instance
*
* @param CakeEventManager $manager
* @param CakeEventManager $manager Optional event manager instance.
* @return CakeEventManager the global event manager
*/
public static function instance($manager = null) {
@ -118,7 +116,7 @@ class CakeEventManager {
* Auxiliary function to attach all implemented callbacks of a CakeEventListener class instance
* as individual methods on this manager
*
* @param CakeEventListener $subscriber
* @param CakeEventListener $subscriber Event listener.
* @return void
*/
protected function _attachSubscriber(CakeEventListener $subscriber) {
@ -256,7 +254,7 @@ class CakeEventManager {
/**
* Returns a list of all listeners for an eventKey in the order they should be called
*
* @param string $eventKey
* @param string $eventKey Event key.
* @return array
*/
public function listeners($eventKey) {
@ -288,7 +286,7 @@ class CakeEventManager {
/**
* Returns the listeners for the specified event key indexed by priority
*
* @param string $eventKey
* @param string $eventKey Event key.
* @return array
*/
public function prioritisedListeners($eventKey) {

View file

@ -48,7 +48,7 @@ class Multibyte {
* Converts a multibyte character string
* to the decimal value of the character
*
* @param string $string
* @param string $string String to convert.
* @return array
*/
public static function utf8($string) {
@ -87,7 +87,7 @@ class Multibyte {
* Converts the decimal value of a multibyte character string
* to a string
*
* @param array $array
* @param array $array Values array.
* @return string
*/
public static function ascii($array) {
@ -728,7 +728,7 @@ class Multibyte {
*
* @param string $string value to encode
* @param string $charset charset to use for encoding. defaults to UTF-8
* @param string $newline
* @param string $newline Newline string.
* @return string
*/
public static function mimeEncode($string, $charset = null, $newline = "\r\n") {
@ -774,7 +774,7 @@ class Multibyte {
/**
* Return the Code points range for Unicode characters
*
* @param integer $decimal
* @param integer $decimal Decimal value.
* @return string
*/
protected static function _codepoint($decimal) {
@ -823,7 +823,7 @@ class Multibyte {
* Find the related code folding values for $char
*
* @param integer $char decimal value of character
* @param string $type
* @param string $type Type 'lower' or 'upper'. Defaults to 'lower'.
* @return array
*/
protected static function _find($char, $type = 'lower') {
@ -860,7 +860,8 @@ class Multibyte {
/**
* Check the $string for multibyte characters
* @param string $string value to test
*
* @param string $string Value to test.
* @return boolean
*/
public static function checkMultibyte($string) {

View file

@ -599,7 +599,7 @@ class CakeSchema extends Object {
/**
* Formats Schema columns from Model Object
*
* @param array $Obj model object
* @param array &$Obj model object
* @return array Formatted columns
*/
protected function _columns(&$Obj) {

View file

@ -119,7 +119,7 @@ class ModelValidator implements ArrayAccess, IteratorAggregate, Countable {
* If you do not want this to happen, make a copy of `$data` before passing it
* to this method
*
* @param array $data Record data to validate. This should be an array indexed by association name.
* @param array &$data Record data to validate. This should be an array indexed by association name.
* @param array $options Options to use when validating record data (see above), See also $options of validates().
* @return array|boolean If atomic: True on success, or false on failure.
* Otherwise: array similar to the $data array passed, but values are set to true/false
@ -196,7 +196,7 @@ class ModelValidator implements ArrayAccess, IteratorAggregate, Countable {
* If you do not want this to happen, make a copy of `$data` before passing it
* to this method
*
* @param array $data Record data to validate. This should be a numerically-indexed array
* @param array &$data Record data to validate. This should be a numerically-indexed array
* @param array $options Options to use when validating record data (see above), See also $options of validates().
* @return mixed If atomic: True on success, or false on failure.
* Otherwise: array similar to the $data array passed, but values are set to true/false
@ -442,7 +442,7 @@ class ModelValidator implements ArrayAccess, IteratorAggregate, Countable {
/**
* Propagates beforeValidate event
*
* @param array $options
* @param array $options Options to pass to callback.
* @return boolean
*/
protected function _triggerBeforeValidate($options = array()) {

View file

@ -85,7 +85,7 @@ class Dispatcher implements CakeEventListener {
* Attaches all event listeners for this dispatcher instance. Loads the
* dispatcher filters from the configured locations.
*
* @param CakeEventManager $manager
* @param CakeEventManager $manager Event manager instance.
* @return void
* @throws MissingDispatcherFilterException
*/
@ -244,7 +244,7 @@ class Dispatcher implements CakeEventListener {
/**
* Load controller and return controller class name
*
* @param CakeRequest $request
* @param CakeRequest $request Request instance.
* @return string|boolean Name of controller class name
*/
protected function _loadController($request) {

View file

@ -1,7 +1,5 @@
<?php
/**
*
*
* CakePHP(tm) : Rapid Development Framework (http://cakephp.org)
* Copyright (c) Cake Software Foundation, Inc. (http://cakefoundation.org)
*
@ -44,7 +42,7 @@ abstract class DispatcherFilter implements CakeEventListener {
/**
* Constructor.
*
* @param string $setting Configuration settings for the filter.
* @param array $settings Configuration settings for the filter.
*/
public function __construct($settings = array()) {
$this->settings = Hash::merge($this->settings, $settings);

View file

@ -108,7 +108,7 @@ class AssetDispatcher extends DispatcherFilter {
/**
* Builds asset file path based off url
*
* @param string $url
* @param string $url URL
* @return string Absolute path for asset file
*/
protected function _getAssetFile($url) {

View file

@ -113,7 +113,7 @@ class RedirectRoute extends CakeRoute {
* Stop execution of the current script. Wraps exit() making
* testing easier.
*
* @param integer|string $status see http://php.net/exit for values
* @param integer|string $code See http://php.net/exit for values
* @return void
*/
protected function _stop($code = 0) {

View file

@ -636,7 +636,7 @@ class Router {
/**
* Parses a file extension out of a URL, if Router::parseExtensions() is enabled.
*
* @param string $url
* @param string $url URL.
* @return array Returns an array containing the altered URL and the parsed extension.
*/
protected static function _parseExtension($url) {

View file

@ -424,7 +424,7 @@ if (!function_exists('mb_encode_mimeheader')) {
* @param string $str The string being encoded
* @param string $charset specifies the name of the character set in which str is represented in.
* The default value is determined by the current NLS setting (mbstring.language).
* @param string $transfer_encoding specifies the scheme of MIME encoding.
* @param string $transferEncoding specifies the scheme of MIME encoding.
* It should be either "B" (Base64) or "Q" (Quoted-Printable). Falls back to "B" if not given.
* @param string $linefeed specifies the EOL (end-of-line) marker with which
* mb_encode_mimeheader() performs line-folding