Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Removed __construct from all interfaces #11441

Merged
merged 1 commit into from
Feb 25, 2016
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,7 @@
- Fixed issue with `Model::__set` that was setting hidden attributes directly when setters are not declared [#11286](https://github.com/phalcon/cphalcon/issues/11286)
- Added `Phalcon\Cli\DispatcherInterface`, `Phalcon\Cli\TaskInterface`, `Phalcon\Cli\RouterInterface` and `Phalcon\Cli\Router\RouteInterface`.
- Added methods update(), create() and createIfNotExist(array criteria) to `Phalcon\Mvc\Collection`
- Removed `__construct` from all interfaces [#11410](https://github.com/phalcon/cphalcon/issues/11410)

# [2.0.11](https://github.com/phalcon/cphalcon/releases/tag/phalcon-v2.0.11) (????-??-??)
- Fix Model magic set functionality to maintain variable visibility and utilize setter methods.[#11286](https://github.com/phalcon/cphalcon/issues/11286)
Expand Down
4 changes: 2 additions & 2 deletions phalcon/acl/resourceaware.zep
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
+------------------------------------------------------------------------+
| Phalcon Framework |
+------------------------------------------------------------------------+
| Copyright (c) 2011-2015 Phalcon Team (http://www.phalconphp.com) |
| Copyright (c) 2011-2016 Phalcon Team (http://www.phalconphp.com) |
+------------------------------------------------------------------------+
| This source file is subject to the New BSD License that is bundled |
| with this package in the file docs/LICENSE.txt. |
Expand All @@ -22,7 +22,7 @@ namespace Phalcon\Acl;
/**
* Phalcon\Acl\ResourceAware
*
* Interface for classes which could be used in allow method as RESOURCE, ResourceInterface need __construct method so i decided to do this simple interface
* Interface for classes which could be used in allow method as RESOURCE
*/
interface ResourceAware
{
Expand Down
8 changes: 1 addition & 7 deletions phalcon/acl/resourceinterface.zep
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
+------------------------------------------------------------------------+
| Phalcon Framework |
+------------------------------------------------------------------------+
| Copyright (c) 2011-2015 Phalcon Team (http://www.phalconphp.com) |
| Copyright (c) 2011-2016 Phalcon Team (http://www.phalconphp.com) |
+------------------------------------------------------------------------+
| This source file is subject to the New BSD License that is bundled |
| with this package in the file docs/LICENSE.txt. |
Expand All @@ -27,12 +27,6 @@ namespace Phalcon\Acl;
*/
interface ResourceInterface
{

/**
* Phalcon\Acl\ResourceInterface constructor
*/
public function __construct(string! name, description = null);

/**
* Returns the resource name
*/
Expand Down
4 changes: 2 additions & 2 deletions phalcon/acl/roleaware.zep
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
+------------------------------------------------------------------------+
| Phalcon Framework |
+------------------------------------------------------------------------+
| Copyright (c) 2011-2015 Phalcon Team (http://www.phalconphp.com) |
| Copyright (c) 2011-2016 Phalcon Team (http://www.phalconphp.com) |
+------------------------------------------------------------------------+
| This source file is subject to the New BSD License that is bundled |
| with this package in the file docs/LICENSE.txt. |
Expand All @@ -22,7 +22,7 @@ namespace Phalcon\Acl;
/**
* Phalcon\Acl\RoleAware
*
* Interface for classes which could be used in allow method as ROLE, RoleInterace need __construct method so i decided to do this simple interface
* Interface for classes which could be used in allow method as ROLE
*/
interface RoleAware
{
Expand Down
8 changes: 1 addition & 7 deletions phalcon/acl/roleinterface.zep
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
+------------------------------------------------------------------------+
| Phalcon Framework |
+------------------------------------------------------------------------+
| Copyright (c) 2011-2015 Phalcon Team (http://www.phalconphp.com) |
| Copyright (c) 2011-2016 Phalcon Team (http://www.phalconphp.com) |
+------------------------------------------------------------------------+
| This source file is subject to the New BSD License that is bundled |
| with this package in the file docs/LICENSE.txt. |
Expand All @@ -26,12 +26,6 @@ namespace Phalcon\Acl;
*/
interface RoleInterface
{

/**
* Phalcon\Acl\Role constructor
*/
public function __construct(string! name, string description = null);

/**
* Returns the role name
*/
Expand Down
8 changes: 1 addition & 7 deletions phalcon/cli/router/routeinterface.zep
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
+------------------------------------------------------------------------+
| Phalcon Framework |
+------------------------------------------------------------------------+
| Copyright (c) 2011-2015 Phalcon Team (http://www.phalconphp.com) |
| Copyright (c) 2011-2016 Phalcon Team (http://www.phalconphp.com) |
+------------------------------------------------------------------------+
| This source file is subject to the New BSD License that is bundled |
| with this package in the file docs/LICENSE.txt. |
Expand All @@ -26,12 +26,6 @@ namespace Phalcon\Cli\Router;
*/
interface RouteInterface
{

/**
* Phalcon\Cli\Router\Route constructor
*/
public function __construct(string! pattern, var paths = null);

/**
* Replaces placeholders from pattern returning a valid PCRE regular expression
*/
Expand Down
8 changes: 1 addition & 7 deletions phalcon/db/adapterinterface.zep
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
+------------------------------------------------------------------------+
| Phalcon Framework |
+------------------------------------------------------------------------+
| Copyright (c) 2011-2015 Phalcon Team (http://www.phalconphp.com) |
| Copyright (c) 2011-2016 Phalcon Team (http://www.phalconphp.com) |
+------------------------------------------------------------------------+
| This source file is subject to the New BSD License that is bundled |
| with this package in the file docs/LICENSE.txt. |
Expand All @@ -26,12 +26,6 @@ namespace Phalcon\Db;
*/
interface AdapterInterface
{

/**
* Constructor for Phalcon\Db\Adapter
*/
public function __construct(array! descriptor);

/**
* Returns the first row in a SQL query result
*
Expand Down
8 changes: 1 addition & 7 deletions phalcon/db/columninterface.zep
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
+------------------------------------------------------------------------+
| Phalcon Framework |
+------------------------------------------------------------------------+
| Copyright (c) 2011-2015 Phalcon Team (http://www.phalconphp.com) |
| Copyright (c) 2011-2016 Phalcon Team (http://www.phalconphp.com) |
+------------------------------------------------------------------------+
| This source file is subject to the New BSD License that is bundled |
| with this package in the file docs/LICENSE.txt. |
Expand All @@ -26,12 +26,6 @@ namespace Phalcon\Db;
*/
interface ColumnInterface
{

/**
* Phalcon\Db\ColumnInterface constructor
*/
public function __construct(string! columnName, array! definition);

/**
* Returns schema's table related to column
*
Expand Down
14 changes: 2 additions & 12 deletions phalcon/db/indexinterface.zep
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
+------------------------------------------------------------------------+
| Phalcon Framework |
+------------------------------------------------------------------------+
| Copyright (c) 2011-2015 Phalcon Team (http://www.phalconphp.com) |
| Copyright (c) 2011-2016 Phalcon Team (http://www.phalconphp.com) |
+------------------------------------------------------------------------+
| This source file is subject to the New BSD License that is bundled |
| with this package in the file docs/LICENSE.txt. |
Expand All @@ -26,16 +26,6 @@ namespace Phalcon\Db;
*/
interface IndexInterface
{

/**
* Phalcon\Db\Index constructor
*
* @param string indexName
* @param array columns
* @param string type
*/
public function __construct(string! indexName, array! columns, type = null);

/**
* Gets the index name
*
Expand All @@ -62,4 +52,4 @@ interface IndexInterface
*/
public static function __set_state(array! data) -> <IndexInterface>;

}
}
10 changes: 2 additions & 8 deletions phalcon/db/referenceinterface.zep
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
+------------------------------------------------------------------------+
| Phalcon Framework |
+------------------------------------------------------------------------+
| Copyright (c) 2011-2015 Phalcon Team (http://www.phalconphp.com) |
| Copyright (c) 2011-2016 Phalcon Team (http://www.phalconphp.com) |
+------------------------------------------------------------------------+
| This source file is subject to the New BSD License that is bundled |
| with this package in the file docs/LICENSE.txt. |
Expand All @@ -26,12 +26,6 @@ namespace Phalcon\Db;
*/
interface ReferenceInterface
{

/**
* Phalcon\Db\ReferenceInterface constructor
*/
public function __construct(string! referenceName, array! definition);

/**
* Gets the index name
*
Expand Down Expand Up @@ -93,4 +87,4 @@ interface ReferenceInterface
*/
public static function __set_state(array! data) -> <ReferenceInterface>;

}
}
14 changes: 1 addition & 13 deletions phalcon/db/resultinterface.zep
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
+------------------------------------------------------------------------+
| Phalcon Framework |
+------------------------------------------------------------------------+
| Copyright (c) 2011-2015 Phalcon Team (http://www.phalconphp.com) |
| Copyright (c) 2011-2016 Phalcon Team (http://www.phalconphp.com) |
+------------------------------------------------------------------------+
| This source file is subject to the New BSD License that is bundled |
| with this package in the file docs/LICENSE.txt. |
Expand All @@ -26,18 +26,6 @@ namespace Phalcon\Db;
*/
interface ResultInterface
{

/**
* Phalcon\Db\Result\Pdo constructor
*
* @param \Phalcon\Db\AdapterInterface connection
* @param \PDOStatement result
* @param string sqlStatement
* @param array bindParams
* @param array bindTypes
*/
public function __construct(<\Phalcon\Db\AdapterInterface> connection, <\PDOStatement> result, sqlStatement = null, bindParams = null, bindTypes = null);

/**
* Allows to executes the statement again. Some database systems don't support scrollable cursors,
* So, as cursors are forward only, we need to execute the cursor again to fetch rows from the begining
Expand Down
12 changes: 1 addition & 11 deletions phalcon/di/serviceinterface.zep
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
+------------------------------------------------------------------------+
| Phalcon Framework |
+------------------------------------------------------------------------+
| Copyright (c) 2011-2015 Phalcon Team (http://www.phalconphp.com) |
| Copyright (c) 2011-2016 Phalcon Team (http://www.phalconphp.com) |
+------------------------------------------------------------------------+
| This source file is subject to the New BSD License that is bundled |
| with this package in the file docs/LICENSE.txt. |
Expand All @@ -26,16 +26,6 @@ namespace Phalcon\Di;
*/
interface ServiceInterface
{

/**
* Phalcon\Di\ServiceInterface
*
* @param string name
* @param mixed definition
* @param boolean shared
*/
public function __construct(string name, definition, boolean shared = false);

/**
* Returns the service's name
*
Expand Down
10 changes: 2 additions & 8 deletions phalcon/http/request/fileinterface.zep
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
+------------------------------------------------------------------------+
| Phalcon Framework |
+------------------------------------------------------------------------+
| Copyright (c) 2011-2015 Phalcon Team (http://www.phalconphp.com) |
| Copyright (c) 2011-2016 Phalcon Team (http://www.phalconphp.com) |
+------------------------------------------------------------------------+
| This source file is subject to the New BSD License that is bundled |
| with this package in the file docs/LICENSE.txt. |
Expand All @@ -27,12 +27,6 @@ namespace Phalcon\Http\Request;
*/
interface FileInterface
{

/**
* Phalcon\Http\Request\FileInterface constructor
*/
public function __construct(array! file, key = null);

/**
* Returns the file size of the uploaded file
*/
Expand Down Expand Up @@ -64,4 +58,4 @@ interface FileInterface
*/
public function moveTo(string! destination) -> boolean;

}
}
12 changes: 2 additions & 10 deletions phalcon/mvc/collection/behaviorinterface.zep
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
+------------------------------------------------------------------------+
| Phalcon Framework |
+------------------------------------------------------------------------+
| Copyright (c) 2011-2015 Phalcon Team (http://www.phalconphp.com) |
| Copyright (c) 2011-2016 Phalcon Team (http://www.phalconphp.com) |
+------------------------------------------------------------------------+
| This source file is subject to the New BSD License that is bundled |
| with this package in the file docs/LICENSE.txt. |
Expand All @@ -28,14 +28,6 @@ use Phalcon\Mvc\CollectionInterface;
*/
interface BehaviorInterface
{

/**
* Phalcon\Mvc\Collection\Behavior
*
* @param array options
*/
public function __construct(options = null);

/**
* This method receives the notifications from the EventsManager
*/
Expand All @@ -46,4 +38,4 @@ interface BehaviorInterface
*/
public function missingMethod(<CollectionInterface> collection, string !method, arguments = null);

}
}
10 changes: 1 addition & 9 deletions phalcon/mvc/model/behaviorinterface.zep
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
+------------------------------------------------------------------------+
| Phalcon Framework |
+------------------------------------------------------------------------+
| Copyright (c) 2011-2015 Phalcon Team (http://www.phalconphp.com) |
| Copyright (c) 2011-2016 Phalcon Team (http://www.phalconphp.com) |
+------------------------------------------------------------------------+
| This source file is subject to the New BSD License that is bundled |
| with this package in the file docs/LICENSE.txt. |
Expand All @@ -28,14 +28,6 @@ use Phalcon\Mvc\ModelInterface;
*/
interface BehaviorInterface
{

/**
* Phalcon\Mvc\Model\Behavior
*
* @param array options
*/
public function __construct(options = null);

/**
* This method receives the notifications from the EventsManager
*/
Expand Down
12 changes: 1 addition & 11 deletions phalcon/mvc/model/messageinterface.zep
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
+------------------------------------------------------------------------+
| Phalcon Framework |
+------------------------------------------------------------------------+
| Copyright (c) 2011-2015 Phalcon Team (http://www.phalconphp.com) |
| Copyright (c) 2011-2016 Phalcon Team (http://www.phalconphp.com) |
+------------------------------------------------------------------------+
| This source file is subject to the New BSD License that is bundled |
| with this package in the file docs/LICENSE.txt. |
Expand All @@ -26,16 +26,6 @@ namespace Phalcon\Mvc\Model;
*/
interface MessageInterface
{

/**
* Phalcon\Mvc\Model\Message constructor
*
* @param string message
* @param string field
* @param string type
*/
public function __construct(message, field = null, type = null);

/**
* Sets message type
*
Expand Down
Loading