Example #1
0
 /**
  * {@inheritdoc}
  */
 public function send($recipient, $body, $originator = '')
 {
     $message = new Sms();
     $message->fromArray(array('recipient' => $recipient, 'body' => $body, 'originator' => $originator, 'status' => ResultInterface::STATUS_QUEUED));
     $this->pool->enqueue($message);
     return $message;
 }
Example #2
0
 /**
  * @param  array                 $data An array of data.
  * @return \SmsSender\Result\Sms
  */
 protected function transformResult(array $data = array())
 {
     $result = new Sms();
     $result->fromArray($data);
     return $result;
 }