Beispiel #1
0
 public function testIsHeadGetterAndSetter()
 {
     $entity = new Email();
     $this->assertTrue($entity->isHead());
     $entity->setHead(false);
     $this->assertFalse($entity->isHead());
 }
Beispiel #2
0
 /**
  * @param Email $email
  * @param bool  $head
  */
 protected function processHead(Email $email, $head)
 {
     if ($email->getId()) {
         if ($email->isHead() != $head) {
             throw $this->createInvalidPropertyException('Head', $email->isHead() ? 'true' : 'false', $head ? 'true' : 'false');
         }
     } else {
         $email->setHead($head);
     }
 }