Created
August 28, 2012 16:34
-
-
Save viniciusss/3500123 to your computer and use it in GitHub Desktop.
Mapeamento tabela chat
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
namespace MDN\Domain\Entity\Customer\Access; | |
/** | |
* | |
* @Table(name="chat") | |
* @Entity(repositoryClass="MDN\Domain\Entity\Customer\Access\ChatRepository") | |
* @author Vinicius de Sa [[email protected]] | |
*/ | |
class Chat { | |
/** | |
* @Id | |
* @Column(name="chat_id") | |
* @var integer | |
* @GeneratedValue(strategy="AUTO") | |
*/ | |
protected $id; | |
/** | |
* | |
* @OneToOne(targetEntity="MDN\Domain\Entity\Customer\Access\User") | |
* @JoinColumn(name="from", referencedColumnName="id") | |
*/ | |
protected $from; | |
/** | |
* | |
* @OneToOne(targetEntity="MDN\Domain\Entity\Customer\Access\User") | |
* @JoinColumn(name="to", referencedColumnName="id") | |
*/ | |
protected $to; | |
/** | |
* | |
* @Column(name="message", type="text") | |
*/ | |
protected $message; | |
/** | |
* @Column(name="sent_at", type="datetime") | |
* @var DateTime | |
*/ | |
protected $sentAt; | |
/** | |
* @Column(name="recd", type="integer") | |
* @var int | |
*/ | |
protected $recd; | |
public function getId() { | |
return $this->id; | |
} | |
public function setId($id) { | |
$this->id = $id; | |
} | |
public function getFrom() { | |
return $this->from; | |
} | |
public function setFrom($from) { | |
$this->from = $from; | |
} | |
public function getTo() { | |
return $this->to; | |
} | |
public function setTo($to) { | |
$this->to = $to; | |
} | |
public function getMessage() { | |
return $this->message; | |
} | |
public function setMessage($message) { | |
$this->message = $message; | |
} | |
public function getSentAt() { | |
return $this->sentAt; | |
} | |
public function setSentAt($sentAt) { | |
$this->sentAt = $sentAt; | |
} | |
public function getRecd() { | |
return $this->recd; | |
} | |
public function setRecd($recd) { | |
$this->recd = $recd; | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment