static function import_php( $package, $silent = false ){
		
		$type = current( explode('.', $package) );
		$paths = self::collect_package( $package, 'php', $silent, 'conf' );
		
		if( !$silent && empty($paths) ){
			trigger_error("Bad import `$package'", E_USER_ERROR );
		}
		
		foreach( $paths as $cname => $path ){
			// leniant inclusion if silent
			if( $silent ){
				include_once $path;
				continue;
			}
			// path should already be validated by collect_package
			require_once $path;
			// Run checks according to type of import
			switch( $type ){
			case 'conf':
				break;
			default:
				// Class or function import must define an entity with the same name as the file
				// testing function first to avoid call to __autoload
				if( ! function_exists($cname) && ! class_exists($cname) ){
					trigger_error( "Class, or function '$cname' not defined in file `$path'", E_USER_ERROR );
				}
			}
		}
	}
static function import_php( $package, $silent = false ){
		
		$type = current( explode('.', $package) );
		$paths = self::collect_package( $package, 'php', $silent, 'conf' );
		
		if( !$silent && empty($paths) ){
			trigger_error("Bad import `$package'", E_USER_ERROR );
		}
		
		foreach( $paths as $cname => $path ){
			// leniant inclusion if silent
			if( $silent ){
				include_once $path;
				continue;
			}
			// path should already be validated by collect_package
			require_once $path;
			// Run checks according to type of import
			switch( $type ){
			case 'conf':
				break;
			default:
				// Class or function import must define an entity with the same name as the file
				// testing function first to avoid call to __autoload
				if( ! function_exists($cname) && ! class_exists($cname) ){
					trigger_error( "Class, or function '$cname' not defined in file `$path'", E_USER_ERROR );
				}
			}
		}
	}
static function import_php ( $ package , $ silent = false ) { $ type = current ( explode ( '.' , $ package ) ) ; $ paths = self :: collect_package ( $ package , 'php' , $ silent , 'conf' ) ; if ( ! $ silent && empty ( $ paths ) ) { trigger_error ( "Bad import `$package'" , E_USER_ERROR ) ; } foreach ( $ paths as $ cname => $ path ) { // leniant inclusion if silent if ( $ silent ) { include_once $ path ; continue ; } // path should already be validated by collect_package require_once $ path ; // Run checks according to type of import switch ( $ type ) { case 'conf' : break ; default : // Class or function import must define an entity with the same name as the file // testing function first to avoid call to __autoload if ( ! function_exists ( $ cname ) && ! class_exists ( $ cname ) ) { trigger_error ( "Class, or function '$cname' not defined in file `$path'" , E_USER_ERROR ) ; } } } }
Import PHP classes and functions into the runtime environment
@param string
@param bool whether to allow silent failure
@return Void
Import PHP classes and functions into the runtime environment