Mage_AmazonPayments_Model_Api_Asp_Fps_Response_Error Class Reference

Inheritance diagram for Mage_AmazonPayments_Model_Api_Asp_Fps_Response_Error:

Mage_AmazonPayments_Model_Api_Asp_Fps_Response_Abstract Varien_Object

List of all members.

Public Member Functions

 getCode ()
 getMessage ()

Protected Member Functions

 parse ($responseBody)


Detailed Description

Definition at line 34 of file Error.php.


Member Function Documentation

getCode (  ) 

Return response Code

Returns:
string

Definition at line 65 of file Error.php.

00066     {
00067         return $this->getData('Code');        
00068     }

getMessage (  ) 

Return response Message

Returns:
string

Definition at line 75 of file Error.php.

00076     {
00077         return $this->getData('Message');        
00078     }

parse ( responseBody  )  [protected]

rewrited for Mage_AmazonPayments_Model_Api_Asp_Fps_Response_Abstract

Reimplemented from Mage_AmazonPayments_Model_Api_Asp_Fps_Response_Abstract.

Definition at line 39 of file Error.php.

00040     {
00041         if ($responseBody->getName() != 'Response') {
00042             return false;
00043         }
00044         
00045         $code = (string)$responseBody->Errors->Error->Code;
00046         $message = (string)$responseBody->Errors->Error->Message;
00047         $responseId = (string)$responseBody->RequestID;
00048         
00049         if($code == '' || $message == '' || $responseId == '') {
00050            return false;   
00051         }
00052         
00053         $this->setData('Id', $responseId);
00054         $this->setData('Status', parent::STATUS_ERROR);
00055         $this->setData('Code', $code);
00056         $this->setData('Message', $message);
00057         return true;
00058     }


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

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