diff options
Diffstat (limited to 'lib/MessageSystems/SendGridCompatibility')
-rw-r--r-- | lib/MessageSystems/SendGridCompatibility/Email.php | 84 | ||||
-rw-r--r-- | lib/MessageSystems/SendGridCompatibility/SDK.php | 24 |
2 files changed, 0 insertions, 108 deletions
diff --git a/lib/MessageSystems/SendGridCompatibility/Email.php b/lib/MessageSystems/SendGridCompatibility/Email.php deleted file mode 100644 index 68c94b7..0000000 --- a/lib/MessageSystems/SendGridCompatibility/Email.php +++ /dev/null @@ -1,84 +0,0 @@ -<?php -namespace MessageSystems\SendGridCompatibility; - -use MessageSystems\Transmission; - -class Email { - private $transmission; - - public function __construct() { - $this->transmission = new Transmission(); - } - - public function send() { - $this->transmission->send(); - } - - public function addTo($address) { - $this->transmission->addRecipient($address); - return $this; - } - - public function setTos(Array $addresses) { - $this->transmission->addRecipients($addresses); - return $this; - } - - /** - * - * @param string $address - * @return \MessageSystems\SendGridCompatibility\Email - */ - public function setFrom($address) { - $this->transmission->setFrom($address); - return $this; - } - - /** - * TODO:figure this out - * @param string $name - */ - public function setFromName($name) { - - return $this; - } - - - /** - * - * @param string $address - * @return \MessageSystems\SendGridCompatibility\Email - */ - public function setReplyTo($address) { - $this->transmission->setReplyTo($address); - return $this; - } - - /** - * TODO: Does this work? - * - * - * @param string $address - * @return \MessageSystems\SendGridCompatibility\Email - */ - public function addBcc($address) { - $this->transmission->addRecipient($address); - return $this; - } - - public function setSubject($subject) { - $this->transmission->setSubject($subject); - return $this; - } - - public function setText($text) { - $this->transmission->setTextContent($text); - return $this; - } - - public function setHtml($html) { - $this->transmission->setHTMLContent($html); - return $this; - } -} -?>
\ No newline at end of file diff --git a/lib/MessageSystems/SendGridCompatibility/SDK.php b/lib/MessageSystems/SendGridCompatibility/SDK.php deleted file mode 100644 index f1a4df3..0000000 --- a/lib/MessageSystems/SendGridCompatibility/SDK.php +++ /dev/null @@ -1,24 +0,0 @@ -<?php -namespace MessageSystems\SendGridCompatibility; - -use MessageSystems\Transmission; -use MessageSystems\SendGridCompatibility\Email; -use MessageSystems\Configuration; - -class SDK{ - private $sparkPost; - - public function __construct($username, $password, $options = null) { - //username isn't used in our system - $opts = ['key'=>$password]; - if (!is_null($options)) { - $opts = array_merge($opts, $options); - } - Configuration::setConfig($opts); - } - - public function send(Email $email) { - $email->send(); - } -} -?>
\ No newline at end of file |