Mage_Api_Model_Server_Adapter_Xmlrpc Class Reference

Inheritance diagram for Mage_Api_Model_Server_Adapter_Xmlrpc:

Varien_Object Mage_Api_Model_Server_Adapter_Interface

List of all members.

Public Member Functions

 setHandler ($handler)
 getHandler ()
 setController (Mage_Api_Controller_Action $controller)
 getController ()
 run ()
 fault ($code, $message)

Protected Attributes

 $_xmlRpc = null


Detailed Description

Definition at line 34 of file Xmlrpc.php.


Member Function Documentation

fault ( code,
message 
)

Dispatch webservice fault

Parameters:
int $code
string $message

Implements Mage_Api_Model_Server_Adapter_Interface.

Definition at line 111 of file Xmlrpc.php.

00112     {
00113         throw new Zend_XmlRpc_Server_Exception($message, $code);
00114     }

getController (  ) 

Retrive webservice api controller

Returns:
Mage_Api_Controller_Action

Implements Mage_Api_Model_Server_Adapter_Interface.

Definition at line 84 of file Xmlrpc.php.

00085     {
00086         return $this->getData('controller');
00087     }

getHandler (  ) 

Retrive handler class name for webservice

Returns:
string

Implements Mage_Api_Model_Server_Adapter_Interface.

Definition at line 62 of file Xmlrpc.php.

00063     {
00064         return $this->getData('handler');
00065     }

run (  ) 

Run webservice

Parameters:
Mage_Api_Controller_Action $controller
Returns:
Mage_Api_Model_Server_Adapter_Xmlrpc

Implements Mage_Api_Model_Server_Adapter_Interface.

Definition at line 95 of file Xmlrpc.php.

00096     {
00097         $this->_xmlRpc = new Zend_XmlRpc_Server();
00098         $this->_xmlRpc->setClass($this->getHandler());
00099         $this->getController()->getResponse()
00100             ->setHeader('Content-Type', 'text/xml')
00101             ->setBody($this->_xmlRpc->handle());
00102         return $this;
00103     }

setController ( Mage_Api_Controller_Action controller  ) 

Set webservice api controller

Parameters:
Mage_Api_Controller_Action $controller
Returns:
Mage_Api_Model_Server_Adapter_Xmlrpc

Implements Mage_Api_Model_Server_Adapter_Interface.

Definition at line 73 of file Xmlrpc.php.

00074     {
00075          $this->setData('controller', $controller);
00076          return $this;
00077     }

setHandler ( handler  ) 

Set handler class name for webservice

Parameters:
string $handler
Returns:
Mage_Api_Model_Server_Adapter_Xmlrpc

Implements Mage_Api_Model_Server_Adapter_Interface.

Definition at line 51 of file Xmlrpc.php.

00052     {
00053         $this->setData('handler', $handler);
00054         return $this;
00055     }


Member Data Documentation

$_xmlRpc = null [protected]

Definition at line 43 of file Xmlrpc.php.


The documentation for this class was generated from the following file:

Generated on Sat Jul 4 17:23:33 2009 for Magento by  doxygen 1.5.8