diff options
| author | Max Kremmel <xing@synapse.plus.com> | 2005-08-24 20:55:17 +0000 |
|---|---|---|
| committer | Max Kremmel <xing@synapse.plus.com> | 2005-08-24 20:55:17 +0000 |
| commit | 2ffdf635ef58937eca0ae3d7c95bc3c052968126 (patch) | |
| tree | a1f5dd55f58263a415f678f74be5a4dd4bf7f112 /LibertySystem.php | |
| parent | 5d100e8078e5a53a70aee8a29080fa00559b4972 (diff) | |
| download | liberty-2ffdf635ef58937eca0ae3d7c95bc3c052968126.tar.gz liberty-2ffdf635ef58937eca0ae3d7c95bc3c052968126.tar.bz2 liberty-2ffdf635ef58937eca0ae3d7c95bc3c052968126.zip | |
synch recent changes from R1 to HEAD
Diffstat (limited to 'LibertySystem.php')
| -rwxr-xr-x | LibertySystem.php | 34 |
1 files changed, 33 insertions, 1 deletions
diff --git a/LibertySystem.php b/LibertySystem.php index 3324937..1c358bf 100755 --- a/LibertySystem.php +++ b/LibertySystem.php @@ -3,7 +3,7 @@ * System class for handling the liberty package * * @package liberty -* @version $Header: /cvsroot/bitweaver/_bit_liberty/LibertySystem.php,v 1.5 2005/08/07 17:40:29 squareing Exp $ +* @version $Header: /cvsroot/bitweaver/_bit_liberty/LibertySystem.php,v 1.6 2005/08/24 20:55:17 squareing Exp $ * @author spider <spider@steelsun.com> */ @@ -26,6 +26,12 @@ define( 'STORAGE_PLUGIN', 'storage' ); define( 'FORMAT_PLUGIN', 'format' ); define( 'DATA_PLUGIN', 'data' ); +define( 'LIBERTY_SERVICE_ACCESS_CONTROL', 'access_control' ); +define( 'LIBERTY_SERVICE_CATEGORIZATION', 'categorization' ); +define( 'LIBERTY_SERVICE_MENU', 'menu' ); +define( 'LIBERTY_SERVICE_DOCUMENT_GENERATION', 'document_generation' ); + + define( 'DEFAULT_ACCEPTABLE_TAGS', '<a><br><b><blockquote><cite><code><div><dd><dl><dt><em><h1><h2><h3><h4><hr>' .' <i><it><img><li><ol><p><pre><span><strong><table><tbody><div><tr><td><th><u><ul>' .' <button><fieldset><form><label><input><option><select><textarea>' ); @@ -118,6 +124,32 @@ class LibertySystem extends LibertyBase { } } + function registerService( $pServiceName, $pPackageName, $pServiceHash ) { + $this->mServices[$pServiceName][$pPackageName] = $pServiceHash; + } + + function hasService( $pServiceName ) { + return( !empty( $this->mServices[$pServiceName] ) ); + } + + function getServiceValues( $pServiceValue ) { + global $gBitSystem; + $ret = NULL; + if( !empty( $this->mServices ) ) { + foreach( array_keys( $this->mServices ) as $service ) { + if( $this->hasService( $service ) ) { + if( !($package = $gBitSystem->getPreference( 'liberty_service_'.$service )) ) { + $package = key( $this->mServices[$service] ); + } + if( !empty( $this->mServices[$service][$package][$pServiceValue] ) ) { + $ret[$service] = $this->mServices[$service][$package][$pServiceValue]; + } + } + } + } + return $ret; + } + function isPluginActive( $pPluginGuid ) { return( isset( $this->mPlugins[$pGuid] ) && ($this->mPlugins[$pGuid] == 'y') ); } |
