<?php
/**
 * FormEntry
 * 
 * @author Elze Kool <info@visualmedia.nl>
 */

namespace VisualM\FormBundle\Entity;

use DateTime;
use Doctrine\ORM\Mapping as ORM;
use Gedmo\Mapping\Annotation as Gedmo;
use VisualM\FormBundle\Model\FormEntryModel;

/**
 * FormEntry
 *
 * @ORM\Entity(repositoryClass="FormEntryRepository")
 * @ORM\Table(name="form_entry")
 * 
 * @author Elze Kool <info@visualmedia.nl>
 */
class FormEntry extends FormEntryModel
{
    /**
     * @var int
     * @ORM\Column(name="id", type="integer")
     * @ORM\Id
     * @ORM\GeneratedValue(strategy="AUTO")
     */
    private $id;

    /**
     * @var Form
     * @ORM\ManyToOne(targetEntity="Form", inversedBy="entries")
     * @ORM\JoinColumn(name="form_id", referencedColumnName="id", nullable = false)
     */
    private $form;

    /**
     * @var string
     * @ORM\Column(name="remoteAddr", type="string", nullable = true)
     */
    private $remoteAddr;

    /**
     * @var string
     * @ORM\Column(name="browser", type="string", nullable = true)
     */
    private $browser;

    /**
     * @var string
     * @ORM\Column(name="landing_url", type="string", nullable = true)
     */
    private $landingUrl;

    /**
     * @var string
     * @ORM\Column(name="landing_referer", type="string", nullable = true)
     */
    private $landingReferer;

    /**
     * @var string
     * @ORM\Column(name="time_on_site_in_sec", type="integer", nullable = true)
     */
    private $timeOnSiteInSec;

    /**
     * @var string
     * @ORM\Column(name="url", type="string", nullable = true)
     */
    private $url;

    /**
     * @var string
     * @ORM\Column(name="status", type="string", nullable = true)
     */
    private $status;

    /**
     * @var array
     * @ORM\Column(name="rawdata", type="array")
     */
    private $rawdata;

    /**
     * @var string
     * @ORM\Column(name="email_html", type="text", nullable = true)
     */
    private $emailHtml;

    /**
     * @var string
     * @ORM\Column(name="kopie_email_html", type="text", nullable = true)
     */
    private $kopieEmailHtml;

    /**
     * @var DateTime
     * @Gedmo\Timestampable(on="create")
     * @ORM\Column(name="toegevoegd", type="datetime")
     */
    protected $toegevoegd;

    /**
     * Get Id
     *
     * @return int Id
     **/
    public function getId()
    {
        return $this->id;
    }

    /**
     * Get Form
     *
     * @return Form Form
     **/
    public function getForm()
    {
        return $this->form;
    }

    /**
     * Set Form
     *
     * @param Form $form Form
     **/
    public function setForm($form)
    {
        $this->form = $form;
    }

    /**
     * Get Remote Addr
     *
     * @return string Remote Addr
     **/
    public function getRemoteAddr()
    {
        return $this->remoteAddr;
    }

    /**
     * Set Remote Addr
     *
     * @param string $remoteAddr Remote Addr
     **/
    public function setRemoteAddr($remoteAddr)
    {
        $this->remoteAddr = $remoteAddr;
    }

    /**
     * Get Browser
     *
     * @return string Browser
     **/
    public function getBrowser()
    {
        return $this->browser;
    }

    /**
     * Set Browser
     *
     * @param string $browser Browser
     **/
    public function setBrowser($browser)
    {
        $this->browser = $browser;
    }

    /**
     * Get LandingUrl
     *
     * @return string LandingUrl
     **/
    public function getLandingUrl()
    {
        return $this->landingUrl;
    }

    /**
     * Set LandingUrl
     *
     * @param string $landingUrl LandingUrl
     **/
    public function setLandingUrl($landingUrl)
    {
        $this->landingUrl = $landingUrl;
    }

    /**
     * Get LandingReferer
     *
     * @return string LandingReferer
     **/
    public function getLandingReferer()
    {
        return $this->landingReferer;
    }

    /**
     * Set LandingReferer
     *
     * @param string $landingReferer LandingReferer
     **/
    public function setLandingReferer($landingReferer)
    {
        $this->landingReferer = $landingReferer;
    }

    /**
     * Get Time On Site in Sec
     *
     * @return int Time On Site in Sec
     **/
    public function getTimeOnSiteInSec()
    {
        return $this->timeOnSiteInSec;
    }

    /**
     * Set Time On Site in Sec
     *
     * @param int $timeOnSiteInSec Time On Site in Sec
     **/
    public function setTimeOnSiteInSec($timeOnSiteInSec)
    {
        $this->timeOnSiteInSec = $timeOnSiteInSec;
    }

    /**
     * Get Url
     *
     * @return string Url
     **/
    public function getUrl()
    {
        return $this->url;
    }

    /**
     * Set Url
     *
     * @param string $url Url
     **/
    public function setUrl($url)
    {
        $this->url = $url;
    }

    /**
     * Get Status
     *
     * @return string Status
     **/
    public function getStatus() {
        return $this->status;
    }

    /**
     * Set Status
     *
     * @param string $status Status
     **/
    public function setStatus($status) {
        $this->status = $status;
    }
    

    /**
     * Get Raw Data
     *
     * @return array Raw Data
     **/
    public function getRawdata()
    {
        return $this->rawdata;
    }

    /**
     * Set Raw Data
     *
     * @param array $rawdata Raw Data
     **/
    public function setRawdata($rawdata)
    {
        $this->rawdata = $rawdata;
    }

    /**
     * Get Email HTML
     *
     * @return string Email HTML
     **/
    public function getEmailHtml()
    {
        return $this->emailHtml;
    }

    /**
     * Set Email HTML
     *
     * @param string $emailHtml Email HTML
     **/
    public function setEmailHtml($emailHtml)
    {
        $this->emailHtml = $emailHtml;
    }

    /**
     * Get Kopie E-mail HTML
     *
     * @return string Kopie E-mail HTML
     **/
    public function getKopieEmailHtml()
    {
        return $this->kopieEmailHtml;
    }

    /**
     * Set Kopie E-mail HTML
     *
     * @param string $kopieEmailHtml Kopie E-mail HTML
     **/
    public function setKopieEmailHtml($kopieEmailHtml)
    {
        $this->kopieEmailHtml = $kopieEmailHtml;
    }

    /**
     * Get Toegevoegd
     *
     * @return DateTime Toegevoegd
     **/
    public function getToegevoegd()
    {
        return $this->toegevoegd;
    }

    /**
     * Set Toegevoegd
     *
     * @param DateTime $toegevoegd Toegevoegd
     **/
    public function setToegevoegd($toegevoegd)
    {
        $this->toegevoegd = $toegevoegd;
    }
}

