Skip to content

Commit

Permalink
Zend Framework 2
Browse files Browse the repository at this point in the history
Добавляем основные файлы ZF2. В будущем запланировано переписывание движка с использованием данного фреймворка.
  • Loading branch information
Exileum committed Nov 24, 2014
1 parent 92172c8 commit 1ac86c5
Show file tree
Hide file tree
Showing 2,482 changed files with 298,793 additions and 0 deletions.
71 changes: 71 additions & 0 deletions library/Zend/Authentication/Adapter/AbstractAdapter.php
@@ -0,0 +1,71 @@
<?php
/**
* Zend Framework (http://framework.zend.com/)
*
* @link http://github.com/zendframework/zf2 for the canonical source repository
* @copyright Copyright (c) 2005-2014 Zend Technologies USA Inc. (http://www.zend.com)
* @license http://framework.zend.com/license/new-bsd New BSD License
*/

namespace Zend\Authentication\Adapter;

abstract class AbstractAdapter implements ValidatableAdapterInterface
{
/**
* @var mixed
*/
protected $credential;

/**
* @var mixed
*/
protected $identity;

/**
* Returns the credential of the account being authenticated, or
* NULL if none is set.
*
* @return mixed
*/
public function getCredential()
{
return $this->credential;
}

/**
* Sets the credential for binding
*
* @param mixed $credential
* @return AbstractAdapter
*/
public function setCredential($credential)
{
$this->credential = $credential;

return $this;
}

/**
* Returns the identity of the account being authenticated, or
* NULL if none is set.
*
* @return mixed
*/
public function getIdentity()
{
return $this->identity;
}

/**
* Sets the identity for binding
*
* @param mixed $identity
* @return AbstractAdapter
*/
public function setIdentity($identity)
{
$this->identity = $identity;

return $this;
}
}
21 changes: 21 additions & 0 deletions library/Zend/Authentication/Adapter/AdapterInterface.php
@@ -0,0 +1,21 @@
<?php
/**
* Zend Framework (http://framework.zend.com/)
*
* @link http://github.com/zendframework/zf2 for the canonical source repository
* @copyright Copyright (c) 2005-2014 Zend Technologies USA Inc. (http://www.zend.com)
* @license http://framework.zend.com/license/new-bsd New BSD License
*/

namespace Zend\Authentication\Adapter;

interface AdapterInterface
{
/**
* Performs an authentication attempt
*
* @return \Zend\Authentication\Result
* @throws \Zend\Authentication\Adapter\Exception\ExceptionInterface If authentication cannot be performed
*/
public function authenticate();
}
17 changes: 17 additions & 0 deletions library/Zend/Authentication/Adapter/DbTable.php
@@ -0,0 +1,17 @@
<?php
/**
* Zend Framework (http://framework.zend.com/)
*
* @link http://github.com/zendframework/zf2 for the canonical source repository
* @copyright Copyright (c) 2005-2014 Zend Technologies USA Inc. (http://www.zend.com)
* @license http://framework.zend.com/license/new-bsd New BSD License
*/

namespace Zend\Authentication\Adapter;

/**
* @deprecated
*/
class DbTable extends DbTable\CredentialTreatmentAdapter
{
}

0 comments on commit 1ac86c5

Please sign in to comment.