<?php

namespace AppBundle\Entity\Organization;

use AppBundle\Entity\Traits\CreatorUpdaterEntity;
use Doctrine\ORM\Mapping as ORM;
use Dunglas\ApiBundle\Annotation\Iri;
use Symfony\Component\Serializer\Annotation\Groups;
use Symfony\Component\Validator\Constraints as Assert;

/**
 * Type générique d'activités
 *
 * @Iri("http://schema.org/ActivityType")
 */
#[ORM\Entity]
class ActivityType
{
    use CreatorUpdaterEntity;
    /**
     * @var int
     */
    #[ORM\Column(type: 'integer')]
    #[ORM\Id]
    #[ORM\GeneratedValue(strategy: 'AUTO')]
    #[Groups(['activitytype', 'activity_reference', 'network_list_activities'])]
    private $id;
    /**
     * @var string
     */
    #[ORM\Column(type: 'string')]
    #[Assert\Type(type: 'string')]
    #[Assert\Choice(callback: ['\AppBundle\Enum\Organization\FamillyTypeEnum', 'toArray'])]
    #[Groups(['activitytype', 'network_list_activities'])]
    private $famillyType;
    /**
     * @var string
     */
    #[ORM\Column(type: 'string', nullable: false)]
    #[Assert\Type(type: 'string')]
    #[Assert\NotNull]
    #[Assert\Choice(callback: ['\AppBundle\Enum\Organization\SubFamillyTypeEnum', 'toArray'])]
    #[Groups(['activitytype', 'activity_reference_activitytype', 'network_list_activities'])]
    private $subFamillyType;
    /**
     * Sets id.
     * 
     * @param int $id
     * 
     * @return $this
     */
    public function setId($id)
    {
        $this->id = $id;

        return $this;
    }
    /**
     * Gets id.
     * 
     * @return int
     */
    public function getId()
    {
        return $this->id;
    }
    /**
     * Set famillyType
     *
     * @param string $famillyType
     *
     * @return ActivityType
     */
    public function setFamillyType($famillyType)
    {
        $this->famillyType = $famillyType;

        return $this;
    }
    /**
     * Get famillyType
     *
     * @return string
     */
    public function getFamillyType()
    {
        return $this->famillyType;
    }
    /**
     * Set subFamillyType
     *
     * @param string $subFamillyType
     *
     * @return ActivityType
     */
    public function setSubFamillyType($subFamillyType)
    {
        $this->subFamillyType = $subFamillyType;

        return $this;
    }
    /**
     * Get subFamillyType
     *
     * @return string
     */
    public function getSubFamillyType()
    {
        return $this->subFamillyType;
    }
}
