__construct() public method

Instantiate the auth object
public __construct ( Pop\Auth\Adapter\AdapterInterface $adapter, integer $encryption, array $options = [] ) : Auth
$adapter Pop\Auth\Adapter\AdapterInterface
$encryption integer
$options array
return Auth
Ejemplo n.º 1
0
 /**
  * Constructor
  *
  * Instantiate the auth object
  *
  * @param int    $encryption
  * @param string $salt
  * @return \Phire\Auth\Auth
  */
 public function __construct($encryption = 0, $salt = null)
 {
     $adapter = new A\Adapter\Table('Phire\\Table\\Users', 'username', 'password', 'role_id');
     parent::__construct($adapter, $encryption);
 }
Ejemplo n.º 2
0
 /**
  * Constructor
  *
  * Instantiate the auth object
  *
  * @param int    $encryption
  * @param string $salt
  */
 public function __construct($encryption = Authentication\Auth::ENCRYPT_MD5, $salt = null)
 {
     $adapter = new Authentication\Adapter\Table('LaceCart\\Backend\\Admin', $encryption);
     $adapter->setUsernameField('email')->setPasswordField('password');
     parent::__construct($adapter, $encryption);
 }