Core
3.2
PHP API documentation
Main Page
Related Pages
Namespaces
Data Structures
Files
Examples
File List
Globals
All
Data Structures
Namespaces
Files
Functions
Variables
Pages
Class.Provider.php
Go to the documentation of this file.
1
<?php
2
/*
3
* @author Anakeen
4
* @package FDL
5
*/
6
/**
7
* provider abstract class
8
*
9
* @author Anakeen
10
* @version $Id: $
11
* @package FDL
12
*/
13
/**
14
*/
15
/**
16
* Class Provider
17
* @method initializeUser
18
*/
19
abstract
class
Provider
20
{
21
22
public
$parms
;
23
public
$pname
;
24
public
$errno
;
25
26
const
ERRNO_BUG_639
= 1;
27
28
public
function
__construct
($authprovider,
$parms
)
29
{
30
$this->parms =
$parms
;
31
$this->pname = strtolower($authprovider);
32
$this->errno = 0;
33
}
34
35
abstract
function
validateCredential
($username, $password);
36
37
public
function
validateAuthorization
($opt)
38
{
39
return
true
;
40
}
41
42
public
function
canICreateUser
()
43
{
44
if
(array_key_exists(
'allowAutoFreedomUserCreation'
, $this->parms) && strtolower($this->parms{
'allowAutoFreedomUserCreation'
}) ==
'yes'
&& is_callable(array(
45
$this,
46
'initializeUser'
47
))) {
48
$this->errno = 0;
49
return
TRUE;
50
}
51
$this->errno = 0;
52
return
FALSE;
53
}
54
}
Provider\canICreateUser
canICreateUser()
Definition:
Class.Provider.php:42
Provider\__construct
__construct($authprovider, $parms)
Definition:
Class.Provider.php:28
Provider\validateAuthorization
validateAuthorization($opt)
Definition:
Class.Provider.php:37
Provider\validateCredential
validateCredential($username, $password)
Provider
Definition:
Class.Provider.php:19
Provider\$errno
$errno
Definition:
Class.Provider.php:24
Provider\$pname
$pname
Definition:
Class.Provider.php:23
Provider\ERRNO_BUG_639
const ERRNO_BUG_639
Definition:
Class.Provider.php:26
Provider\$parms
$parms
Definition:
Class.Provider.php:22
← centre documentaire
© anakeen