+--------------------------------------------------------------------+
| CiviCRM version 4.6 |
+--------------------------------------------------------------------+
- | Copyright CiviCRM LLC (c) 2004-2014 |
+ | Copyright CiviCRM LLC (c) 2004-2015 |
+--------------------------------------------------------------------+
| This file is a part of CiviCRM. |
| |
}
}
+ /**
+ * Getter for the payment processor.
+ *
+ * The payment processor array is based on the civicrm_payment_processor table entry.
+ *
+ * @return array
+ * Payment processor array.
+ */
+ public function getPaymentProcessor() {
+ return $this->_paymentProcessor;
+ }
+
+ /**
+ * Setter for the payment processor.
+ *
+ * @param array $processor
+ */
+ public function setPaymentProcessor($processor) {
+ $this->_paymentProcessor = $processor;
+ }
+
/**
* Setter for the payment form that wants to use the processor.
*
/**
* Getter for accessing member vars.
+ *
* @todo believe this is unused
+ *
* @param string $name
*
* @return null
abstract protected function doDirectPayment(&$params);
/**
- * Process payment - this function wraps around both doTransferPayment and doDirectPayment
- * it ensures an exception is thrown & moves some of this logic out of the form layer and makes the forms more agnostic
+ * Process payment - this function wraps around both doTransferPayment and doDirectPayment.
+ *
+ * The function ensures an exception is thrown & moves some of this logic out of the form layer and makes the forms
+ * more agnostic.
*
* @param array $params
*
abstract protected function checkConfig();
/**
+ * Redirect for paypal.
+ *
+ * @todo move to paypal class or remove
+ *
* @param $paymentProcessor
- * @todo move to paypal class or remover
+ *
* @return bool
*/
public static function paypalRedirect(&$paymentProcessor) {
}
/**
+ * Handle incoming payment notification.
+ *
+ * IPNs, also called silent posts are notifications of payment outcomes or activity on an external site.
+ *
* @todo move to0 \Civi\Payment\System factory method
* Page callback for civicrm/payment/ipn
*/
else {
// This is called when processor_name is passed - passing processor_id instead is recommended.
$sql .= " WHERE ppt.name = %2 AND pp.is_test = %1";
- $args[1] = array((CRM_Utils_Array::value('mode', $params) == 'test') ? 1 : 0, 'Integer');
+ $args[1] = array(
+ (CRM_Utils_Array::value('mode', $params) == 'test') ? 1 : 0,
+ 'Integer',
+ );
$args[2] = array($params['processor_name'], 'String');
$notFound = "No active instances of the '{$params['processor_name']}' payment processor were found.";
}