nyroFwk
0.2
var
www
users
nyrofwk
src
nyro
lib.class.php
Go to the documentation of this file.
1
<?php
10
final
class
lib
{
11
17
private
static
$libFiles
= array();
18
22
private
function
__construct
() {}
23
31
public
static
function
exists
($name) {
32
return
!(self::initFile($name) ===
false
);
33
}
34
41
public
static
function
isLoaded
($name) {
42
return
in_array(str_replace(array(
'/'
,
'\\'
), array(
DS
,
DS
), self::initFile($name)), get_included_files());
43
}
44
51
public
static
function
load
($name) {
52
if
(self::isLoaded($name))
53
return
true
;
54
55
if
($file = self::initFile($name))
56
return
require($file);
57
58
return
false
;
59
}
60
68
public
static
function
initFile
($name) {
69
if
(!array_key_exists($name, self::$libFiles)) {
70
self::$libFiles[$name] =
file::nyroExists
(array(
71
'name'
=>
'lib_'
.$name.
'_init'
,
72
'type'
=>
'lib'
73
));
74
}
75
return
self::$libFiles[$name];
76
}
77
78
}
lib\initFile
static initFile($name)
Definition:
lib.class.php:68
DS
if(!defined('NYROROOT')) define('NYROROOT' ROOT DS
Definition:
start.inc.php:56
lib\__construct
__construct()
Definition:
lib.class.php:22
lib
Definition:
lib.class.php:10
file\nyroExists
static nyroExists($prm)
Definition:
file.class.php:137
lib\$libFiles
static $libFiles
Definition:
lib.class.php:17
lib\exists
static exists($name)
Definition:
lib.class.php:31
lib\load
static load($name)
Definition:
lib.class.php:51
lib\isLoaded
static isLoaded($name)
Definition:
lib.class.php:41
Generated on Sun Oct 15 2017 22:25:20 for nyroFwk by
1.8.13