attachSigner() public method

Detach a signature handler from a message.
public attachSigner ( Swift_Signer $signer ) : Swift_Message
$signer Swift_Signer
return Swift_Message
Ejemplo n.º 1
0
 public function testCloningWithSigners()
 {
     $message1 = new Swift_Message('subj', 'body', 'ctype');
     $signer = new Swift_Signers_DKIMSigner(dirname(dirname(__DIR__)) . '/_samples/dkim/dkim.test.priv', 'test.example', 'example');
     $message1->attachSigner($signer);
     $message2 = new Swift_Message('subj', 'body', 'ctype');
     $signer = new Swift_Signers_DKIMSigner(dirname(dirname(__DIR__)) . '/_samples/dkim/dkim.test.priv', 'test.example', 'example');
     $message2->attachSigner($signer);
     $message1_clone = clone $message1;
     $this->_recursiveObjectCloningCheck($message1, $message2, $message1_clone);
 }
Ejemplo n.º 2
0
 /**
  * {@inheritdoc}
  *
  * @return $this|self
  */
 public function attachSigner(\Swift_Signer $signer) : self
 {
     return $this->message->attachSigner($signer);
 }