<?php
namespace Medienreaktor\Products\Domain\Model;

/***
 *
 * This file is part of the "Products" Extension for TYPO3 CMS.
 *
 * For the full copyright and license information, please read the
 * LICENSE.txt file that was distributed with this source code.
 *
 *  (c) 2017 Daniel Kestler &lt;daniel.kestler@medienreaktor&gt;, medienreaktor GmbH
 *
 ***/

/**
 * Faq
 */
class Faq extends \TYPO3\CMS\Extbase\DomainObject\AbstractEntity
{
    /**
     * question
     *
     * @var string
     */
    protected $question = '';

    /**
     * tt_content
     *
     * @var \TYPO3\CMS\Extbase\Persistence\ObjectStorage<\Medienreaktor\Products\Domain\Model\Content>
     */
    protected $ttContent = NULL;

    /**
     * productgroup
     *
     * @var \TYPO3\CMS\Extbase\Persistence\ObjectStorage<\Medienreaktor\Products\Domain\Model\ProductGroup>
     */
    protected $productgroup = NULL;

    /**
     * Returns the question
     *
     * @return string $question
     */
    public function getQuestion()
    {
        return $this->question;
    }

    /**
     * Sets the question
     *
     * @param string $question
     * @return void
     */
    public function setQuestion($question): void
    {
        $this->question = $question;
    }

    /**
     * Returns the tt_content elements
     *
     * @return \TYPO3\CMS\Extbase\Persistence\ObjectStorage $tt_content
     */
    public function getTtContent() {
        return $this->ttContent;
    }

    /**
     * Sets the tt_content elements
     *
     * @param \TYPO3\CMS\Extbase\Persistence\ObjectStorage $tt_content
     * @return void
     */
    public function setTtContent(\TYPO3\CMS\Extbase\Persistence\ObjectStorage $ttContent): void {
        $this->ttContent = $ttContent;
    }

    /**
     * Returns the productgroups
     *
     * @return \TYPO3\CMS\Extbase\Persistence\ObjectStorage $productgroup
     */
    public function getProductgroup() {
        return $this->productgroup;
    }

    /**
     * Sets the productgroups
     *
     * @param \TYPO3\CMS\Extbase\Persistence\ObjectStorage $productgroup
     * @return void
     */
    public function setProductgroup(\TYPO3\CMS\Extbase\Persistence\ObjectStorage $productgroup): void {
        $this->productgroup = $productgroup;
    }

    /**
     * __construct
     */
    public function __construct() {
        //Do not remove the next line: It would break the functionality
        $this->initStorageObjects();
    }

    /**
     * Initializes all ObjectStorage properties
     * Do not modify this method!
     * It will be rewritten on each save in the extension builder
     * You may modify the constructor of this class instead
     *
     * @return void
     */
    protected function initStorageObjects() {
        $this->ttContent = new \TYPO3\CMS\Extbase\Persistence\ObjectStorage();
        $this->productgroup = new \TYPO3\CMS\Extbase\Persistence\ObjectStorage();
    }

}
