mirror of
https://github.com/yiisoft/yii2.git
synced 2025-08-26 14:26:54 +08:00
Fixed phpdoc types
This commit is contained in:
@ -617,7 +617,7 @@ class Model extends Component implements StaticInstanceInterface, IteratorAggreg
|
||||
/**
|
||||
* Returns the first error of the specified attribute.
|
||||
* @param string $attribute attribute name.
|
||||
* @return string the error message. Null is returned if no error.
|
||||
* @return string|null the error message. Null is returned if no error.
|
||||
* @see getErrors()
|
||||
* @see getFirstErrors()
|
||||
*/
|
||||
|
@ -340,7 +340,7 @@ class Pagination extends BaseObject implements Linkable
|
||||
* This method returns the named parameter value from [[params]]. Null is returned if the value does not exist.
|
||||
* @param string $name the parameter name
|
||||
* @param string $defaultValue the value to be returned when the specified parameter does not exist in [[params]].
|
||||
* @return string the parameter value
|
||||
* @return string|null the parameter value
|
||||
*/
|
||||
protected function getQueryParam($name, $defaultValue = null)
|
||||
{
|
||||
|
@ -881,7 +881,7 @@ class Connection extends Component
|
||||
* Obtains the schema information for the named table.
|
||||
* @param string $name table name.
|
||||
* @param bool $refresh whether to reload the table schema even if it is found in the cache.
|
||||
* @return TableSchema table schema information. Null if the named table does not exist.
|
||||
* @return TableSchema|null table schema information. Null if the named table does not exist.
|
||||
*/
|
||||
public function getTableSchema($name, $refresh = false)
|
||||
{
|
||||
|
@ -64,7 +64,7 @@ class TableSchema extends BaseObject
|
||||
* Gets the named column metadata.
|
||||
* This is a convenient method for retrieving a named column even if it does not exist.
|
||||
* @param string $name column name
|
||||
* @return ColumnSchema metadata of the named column. Null if the named column does not exist.
|
||||
* @return ColumnSchema|null metadata of the named column. Null if the named column does not exist.
|
||||
*/
|
||||
public function getColumn($name)
|
||||
{
|
||||
|
@ -146,7 +146,7 @@ class BaseFileHelper
|
||||
* and this is null, it will use the file specified by [[mimeMagicFile]].
|
||||
* @param bool $checkExtension whether to use the file extension to determine the MIME type in case
|
||||
* `finfo_open()` cannot determine it.
|
||||
* @return string the MIME type (e.g. `text/plain`). Null is returned if the MIME type cannot be determined.
|
||||
* @return string|null the MIME type (e.g. `text/plain`). Null is returned if the MIME type cannot be determined.
|
||||
* @throws InvalidConfigException when the `fileinfo` PHP extension is not installed and `$checkExtension` is `false`.
|
||||
*/
|
||||
public static function getMimeType($file, $magicFile = null, $checkExtension = true)
|
||||
|
@ -37,7 +37,7 @@ abstract class BaseManager extends Component implements ManagerInterface
|
||||
/**
|
||||
* Returns the named auth item.
|
||||
* @param string $name the auth item name.
|
||||
* @return Item the auth item corresponding to the specified name. Null is returned if no such item.
|
||||
* @return Item|null the auth item corresponding to the specified name. Null is returned if no such item.
|
||||
*/
|
||||
abstract protected function getItem($name);
|
||||
|
||||
|
@ -83,7 +83,7 @@ class CookieCollection extends BaseObject implements \IteratorAggregate, \ArrayA
|
||||
/**
|
||||
* Returns the cookie with the specified name.
|
||||
* @param string $name the cookie name
|
||||
* @return Cookie the cookie with the specified name. Null if the named cookie does not exist.
|
||||
* @return Cookie|null the cookie with the specified name. Null if the named cookie does not exist.
|
||||
* @see getValue()
|
||||
*/
|
||||
public function get($name)
|
||||
|
@ -141,7 +141,7 @@ class HeaderCollection extends BaseObject implements \IteratorAggregate, \ArrayA
|
||||
/**
|
||||
* Removes a header.
|
||||
* @param string $name the name of the header to be removed.
|
||||
* @return array the value of the removed header. Null is returned if the header does not exist.
|
||||
* @return array|null the value of the removed header. Null is returned if the header does not exist.
|
||||
*/
|
||||
public function remove($name)
|
||||
{
|
||||
|
Reference in New Issue
Block a user