Skip to content

Commit

Permalink
Bumbed stubs to 4.0.6
Browse files Browse the repository at this point in the history
  • Loading branch information
ruudboon committed May 18, 2020
1 parent 98cb2f5 commit 62065fd
Show file tree
Hide file tree
Showing 73 changed files with 339 additions and 270 deletions.
25 changes: 13 additions & 12 deletions src/Phalcon/Acl/Adapter/AbstractAdapter.php
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
*/
namespace Phalcon\Acl\Adapter;

use Phalcon\Acl\Enum;
use Phalcon\Events\ManagerInterface;

/**
Expand All @@ -19,7 +20,7 @@ abstract class AbstractAdapter implements \Phalcon\Acl\Adapter\AdapterInterface,
/**
* Active access which the list is checking if some role can access it
*
* @var string
* @var string|null
*/
protected $activeAccess;

Expand All @@ -34,38 +35,38 @@ abstract class AbstractAdapter implements \Phalcon\Acl\Adapter\AdapterInterface,
* Role which the list is checking if it's allowed to certain
* component/access
*
* @var string
* @var string|null
*/
protected $activeRole;

/**
* Component which the list is checking if some role can access it
*
* @var string
* @var string|null
*/
protected $activeComponent;

/**
* Default access
*
* @var bool
* @var int
*/
protected $defaultAccess = false;
protected $defaultAccess = Enum::DENY;

/**
* Events manager
*
* @var mixed
* @var ManagerInterface|null
*/
protected $eventsManager;


/**
* Active access which the list is checking if some role can access it
*
* @return string
* @return string|null
*/
public function getActiveAccess(): string
public function getActiveAccess(): ?string
{
}

Expand All @@ -74,18 +75,18 @@ public function getActiveAccess(): string
*
* component/access
*
* @return string
* @return string|null
*/
public function getActiveRole(): string
public function getActiveRole(): ?string
{
}

/**
* Component which the list is checking if some role can access it
*
* @return string
* @return string|null
*/
public function getActiveComponent(): string
public function getActiveComponent(): ?string
{
}

Expand Down
12 changes: 6 additions & 6 deletions src/Phalcon/Acl/Adapter/AdapterInterface.php
Original file line number Diff line number Diff line change
Expand Up @@ -89,25 +89,25 @@ public function dropComponentAccess(string $componentName, $accessList);
/**
* Returns the access which the list is checking if some role can access it
*
* @return string
* @return string|null
*/
public function getActiveAccess(): string;
public function getActiveAccess(): ?string;

/**
* Returns the role which the list is checking if it's allowed to certain
* component/access
*
* @return string
* @return string|null
*/
public function getActiveRole(): string;
public function getActiveRole(): ?string;

/**
* Returns the component which the list is checking if some role can access
* it
*
* @return string
* @return string|null
*/
public function getActiveComponent(): string;
public function getActiveComponent(): ?string;

/**
* Returns the default ACL access level
Expand Down
2 changes: 1 addition & 1 deletion src/Phalcon/Annotations/Adapter/Apcu.php
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ public function __construct(array $options = array())
* Reads parsed annotations from APCu
*
* @param string $key
* @return mixed
* @return bool|\Phalcon\Annotations\Reflection
*/
public function read(string $key)
{
Expand Down
2 changes: 1 addition & 1 deletion src/Phalcon/Annotations/Adapter/Memory.php
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ class Memory extends \Phalcon\Annotations\Adapter\AbstractAdapter
* Reads parsed annotations from memory
*
* @param string $key
* @return mixed
* @return bool|\Phalcon\Annotations\Reflection
*/
public function read(string $key)
{
Expand Down
2 changes: 1 addition & 1 deletion src/Phalcon/Annotations/Adapter/Stream.php
Original file line number Diff line number Diff line change
Expand Up @@ -45,7 +45,7 @@ public function __construct(array $options = array())
* Reads parsed annotations from files
*
* @param string $key
* @return mixed
* @return bool|int|\Phalcon\Annotations\Reflection
*/
public function read(string $key)
{
Expand Down
14 changes: 8 additions & 6 deletions src/Phalcon/Annotations/Annotation.php
Original file line number Diff line number Diff line change
Expand Up @@ -19,19 +19,19 @@ class Annotation
*
* @var array
*/
protected $arguments;
protected $arguments = array();

/**
* Annotation ExprArguments
*
* @var string
* @var array
*/
protected $exprArguments;
protected $exprArguments = array();

/**
* Annotation Name
*
* @var string
* @var string|null
*/
protected $name;

Expand All @@ -49,6 +49,7 @@ public function __construct(array $reflectionData)
* Returns an argument in a specific position
*
* @param mixed $position
* @return mixed|null
*/
public function getArgument($position)
{
Expand Down Expand Up @@ -85,16 +86,17 @@ public function getExpression(array $expr)
/**
* Returns the annotation's name
*
* @return string
* @return string|null
*/
public function getName(): string
public function getName(): ?string
{
}

/**
* Returns a named argument
*
* @param string $name
* @return mixed|null
*/
public function getNamedArgument(string $name)
{
Expand Down
2 changes: 1 addition & 1 deletion src/Phalcon/Annotations/Collection.php
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ public function count(): int
/**
* Returns the current annotation in the iterator
*
* @return mixed
* @return bool|Annotation
*/
public function current()
{
Expand Down
2 changes: 1 addition & 1 deletion src/Phalcon/Annotations/Reflection.php
Original file line number Diff line number Diff line change
Expand Up @@ -56,7 +56,7 @@ public function __construct(array $reflectionData = array())
/**
* Returns the annotations found in the class docblock
*
* @return mixed
* @return bool|Collection
*/
public function getClassAnnotations()
{
Expand Down
4 changes: 2 additions & 2 deletions src/Phalcon/Cli/Router.php
Original file line number Diff line number Diff line change
Expand Up @@ -148,7 +148,7 @@ public function getParams(): array
* Returns a route object by its id
*
* @param int $id
* @return mixed
* @return bool|\Phalcon\Cli\Router\RouteInterface
*/
public function getRouteById($id)
{
Expand All @@ -158,7 +158,7 @@ public function getRouteById($id)
* Returns a route object by its name
*
* @param string $name
* @return mixed
* @return bool|\Phalcon\Cli\Router\RouteInterface
*/
public function getRouteByName(string $name)
{
Expand Down
2 changes: 1 addition & 1 deletion src/Phalcon/Cli/Task.php
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ final public function __construct()
/**
* Returns the internal event manager
*
* @return mixed
* @return \Phalcon\Events\ManagerInterface|null
*/
public function getEventsManager(): ?ManagerInterface
{
Expand Down
2 changes: 1 addition & 1 deletion src/Phalcon/Config.php
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,7 @@ public function merge($toMerge): Config
* @param string $path
* @param mixed $defaultValue
* @param mixed $delimiter
* @return mixed
* @return mixed|null
*/
public function path(string $path, $defaultValue = null, $delimiter = null)
{
Expand Down
9 changes: 5 additions & 4 deletions src/Phalcon/Config/ConfigFactory.php
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@
*/
namespace Phalcon\Config;

use Phalcon\Config;
use Phalcon\Factory\AbstractFactory;

/**
Expand Down Expand Up @@ -47,9 +48,9 @@ public function __construct(array $services = array())
* 'mode' => null,
* 'callbacks' => null
* ]
* @return object
* @return Config
*/
public function load($config)
public function load($config): Config
{
}

Expand All @@ -59,9 +60,9 @@ public function load($config)
* @param string $name
* @param string $fileName
* @param mixed $params
* @return object
* @return Config
*/
public function newInstance(string $name, string $fileName, $params = null)
public function newInstance(string $name, string $fileName, $params = null): Config
{
}

Expand Down
2 changes: 1 addition & 1 deletion src/Phalcon/Crypt.php
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ class Crypt implements \Phalcon\Crypt\CryptInterface
/**
* @var string
*/
protected $key;
protected $key = '';

/**
* @var int
Expand Down
5 changes: 2 additions & 3 deletions src/Phalcon/Db/Adapter/AbstractAdapter.php
Original file line number Diff line number Diff line change
Expand Up @@ -13,10 +13,9 @@
use Phalcon\Db\Enum;
use Phalcon\Db\RawValue;
use Phalcon\Events\ManagerInterface;
use Phalcon\Events\Manager;

/**
* Base class for Phalcon\Db adapters
* Base class for Phalcon\Db\Adapter adapters
*/
abstract class AbstractAdapter implements \Phalcon\Db\Adapter\AdapterInterface, \Phalcon\Events\EventsAwareInterface
{
Expand Down Expand Up @@ -52,7 +51,7 @@ abstract class AbstractAdapter implements \Phalcon\Db\Adapter\AdapterInterface,
/**
* Event Manager
*
* @var Manager
* @var ManagerInterface
*/
protected $eventsManager;

Expand Down
3 changes: 1 addition & 2 deletions src/Phalcon/Db/Adapter/AdapterInterface.php
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,6 @@

use Phalcon\Db\DialectInterface;
use Phalcon\Db\RawValue;
use Phalcon\Db\ResultInterface;

/**
* Interface for Phalcon\Db adapters
Expand Down Expand Up @@ -505,7 +504,7 @@ public function modifyColumn(string $tableName, string $schemaName, \Phalcon\Db\
* @param string $sqlStatement
* @param mixed $placeholders
* @param mixed $dataTypes
* @return ResultInterface|bool
* @return bool|\Phalcon\Db\ResultInterface
*/
public function query(string $sqlStatement, $placeholders = null, $dataTypes = null);

Expand Down
2 changes: 1 addition & 1 deletion src/Phalcon/Db/Adapter/Pdo/AbstractPdo.php
Original file line number Diff line number Diff line change
Expand Up @@ -361,7 +361,7 @@ public function prepare(string $sqlStatement): \PDOStatement
* @param string $sqlStatement
* @param mixed $bindParams
* @param mixed $bindTypes
* @return mixed
* @return bool|\Phalcon\Db\ResultInterface
*/
public function query(string $sqlStatement, $bindParams = null, $bindTypes = null)
{
Expand Down
12 changes: 6 additions & 6 deletions src/Phalcon/Db/Column.php
Original file line number Diff line number Diff line change
Expand Up @@ -207,7 +207,7 @@ class Column implements \Phalcon\Db\ColumnInterface
/**
* Column Position
*
* @var string
* @var string|null
*/
protected $after;

Expand Down Expand Up @@ -271,7 +271,7 @@ class Column implements \Phalcon\Db\ColumnInterface
/**
* Integer column size
*
* @var int
* @var int | string
*/
protected $size = 0;

Expand Down Expand Up @@ -332,9 +332,9 @@ public function getScale(): int
/**
* Integer column size
*
* @return int
* @return int|string
*/
public function getSize(): int
public function getSize()
{
}

Expand Down Expand Up @@ -378,9 +378,9 @@ public function __construct(string $name, array $definition)
/**
* Check whether field absolute to position in table
*
* @return string
* @return string|null
*/
public function getAfterPosition(): string
public function getAfterPosition(): ?string
{
}

Expand Down
Loading

0 comments on commit 62065fd

Please sign in to comment.