oxpaymentgateway.php

Go to the documentation of this file.
00001 <?php
00002 
00008 class oxPaymentGateway extends oxSuperCfg
00009 {
00014     protected $_blActive       = false;
00015 
00020     protected $_oPaymentInfo   = null;
00021 
00027     protected $_iLastErrorNo   = 4;
00028 
00034     protected $_sLastError     = null;
00035 
00043     public function setPaymentParams( $oUserpayment )
00044     {
00045         // store data
00046         $this->_oPaymentInfo = & $oUserpayment;
00047     }
00048 
00057     public function executePayment( $dAmount, & $oOrder )
00058     {
00059         $this->_iLastErrorNo = null;
00060         $this->_sLastError = null;
00061 
00062         if ( !$this->_isActive()) {
00063             return true;    // fake yes
00064         }
00065 
00066         // proceed with no payment
00067         // used for other countries
00068         if (@$this->_oPaymentInfo->oxuserpayments__oxpaymentsid->value == 'oxempty') {
00069             return true;
00070         }
00071 
00072         return false;
00073     }
00074 
00080     public function getLastErrorNo()
00081     {
00082         return $this->_iLastErrorNo;
00083     }
00084 
00090     public function getLastError()
00091     {
00092         return $this->_sLastError;
00093     }
00094 
00100     protected function _isActive()
00101     {
00102         return $this->_blActive;
00103     }
00104 }

Generated by  doxygen 1.6.2