/** * Constructor * * receives options array and sets into body array and parent's construct * accordingly sets parent's $type to "Return Response" * * @param array $options */ protected function __construct(&$options) { parent::__construct($options); //SET BODY foreach ($options as $key => $value) { switch (ucwords(strtolower($key))) { case "Request_trx_no": case "Approval_ind": case "Reject_reason_code": $this->setBodyField($key, $value); break; } } }
/** * Constructor * * receives options array and sets into body array and parent's construct * accordingly sets parent's $type to "Return" * * @param array $options */ protected function __construct(&$options) { parent::__construct($options); //SET BODY foreach ($options as $key => $value) { switch (ucwords(strtolower($key))) { case "Request_trx_no": case "Current_operator": case "Number": $this->setBodyField($key, $value); break; case "Phone_number": $this->setBodyField("Number", $value); break; } } }