Public Member Functions | |
__construct ($sourceData=null) | |
getWsdlContent () | |
getCache () | |
init () | |
getXmlString () | |
Static Public Member Functions | |
static | getNamespacesPrefix () |
Protected Member Functions | |
_loadCache ($id) | |
_saveCache ($data, $id, $tags=array(), $lifetime=false) | |
_removeCache ($id) | |
Static Protected Attributes | |
static | $_namespacesPrefix = null |
Definition at line 34 of file Config.php.
__construct | ( | $ | sourceData = null |
) |
Constructor
Initializes XML for this configuration
string|Varien_Simplexml_Element | $sourceData | |
string | $sourceType |
Reimplemented from Mage_Api_Model_Wsdl_Config_Base.
Definition at line 38 of file Config.php.
00039 { 00040 $this->setCacheId('wsdl_config_global'); 00041 parent::__construct($sourceData); 00042 }
_loadCache | ( | $ | id | ) | [protected] |
Enter description here...
string | $id |
Reimplemented from Varien_Simplexml_Config.
Definition at line 76 of file Config.php.
00077 { 00078 return Mage::app()->loadCache($id); 00079 }
_removeCache | ( | $ | id | ) | [protected] |
Enter description here...
string | $id |
Reimplemented from Varien_Simplexml_Config.
Definition at line 86 of file Config.php.
00087 { 00088 return Mage::app()->removeCache($id); 00089 }
_saveCache | ( | $ | data, | |
$ | id, | |||
$ | tags = array() , |
|||
$ | lifetime = false | |||
) | [protected] |
Enter description here...
string | $data | |
string | $id | |
array | $tags | |
int|boolean | $lifetime |
Reimplemented from Varien_Simplexml_Config.
Definition at line 81 of file Config.php.
getCache | ( | ) |
Enter description here...
Reimplemented from Varien_Simplexml_Config.
Definition at line 71 of file Config.php.
00072 { 00073 return Mage::app()->getCache(); 00074 }
static getNamespacesPrefix | ( | ) | [static] |
Return namespaces with their prefix
Definition at line 59 of file Config.php.
00060 { 00061 if (is_null(self::$_namespacesPrefix)) { 00062 self::$_namespacesPrefix = array(); 00063 $config = Mage::getSingleton('api/config')->getNode('v2/wsdl/prefix')->children(); 00064 foreach ($config as $prefix => $namespace) { 00065 self::$_namespacesPrefix[$namespace->asArray()] = $prefix; 00066 } 00067 } 00068 return self::$_namespacesPrefix; 00069 }
getWsdlContent | ( | ) |
getXmlString | ( | ) |
Return Xml of node as string
Reimplemented from Varien_Simplexml_Config.
Definition at line 128 of file Config.php.
00129 { 00130 return $this->getNode()->asXML(); 00131 }
init | ( | ) |
Exclude Mage_Api wsdl xml file because it used for previous version of API wsdl declaration
Definition at line 91 of file Config.php.
00092 { 00093 $this->setCacheChecksum(null); 00094 $saveCache = true; 00095 00096 if (Mage::app()->useCache('config')) { 00097 $loaded = $this->loadCache(); 00098 if ($loaded) { 00099 return $this; 00100 } 00101 } 00102 00103 $mergeWsdl = new Mage_Api_Model_Wsdl_Config_Base(); 00104 $mergeWsdl->setHandler($this->getHandler()); 00105 00106 /** 00107 * Exclude Mage_Api wsdl xml file because it used for previous version 00108 * of API wsdl declaration 00109 */ 00110 $mergeWsdl->addLoadedFile(Mage::getConfig()->getModuleDir('etc', "Mage_Api").DS.'wsdl.xml'); 00111 00112 $baseWsdlFile = Mage::getConfig()->getModuleDir('etc', "Mage_Api").DS.'wsdl2.xml'; 00113 $this->loadFile($baseWsdlFile); 00114 Mage::getConfig()->loadModulesConfiguration('wsdl.xml', $this, $mergeWsdl); 00115 00116 if (Mage::app()->useCache('config')) { 00117 $this->saveCache(array('config')); 00118 } 00119 00120 return $this; 00121 }
$_namespacesPrefix = null [static, protected] |
Definition at line 36 of file Config.php.