<?php
/**
 * Quote Conversation Model
 *
 * @category  Magetop Extensions
 * @package   Magetop_Quotesystem
 * @author    Magetop Developer
 * @copyright Copyright (c) Magetop (https://www.magetop.com)
 * @license   https://www.magetop.com/license.html
 */

namespace Magetop\Quotesystem\Model;

use Magetop\Quotesystem\Api\Data\QuoteConversationInterface;
use Magento\Framework\DataObject\IdentityInterface;
use \Magento\Framework\Model\AbstractModel;

class Quoteconversation extends AbstractModel implements QuoteConversationInterface, IdentityInterface
{
   
    public const CACHE_TAG = 'quotesystem_quoteconversation';

    /**
     * @var string
     */
    protected $_cacheTag = 'quotesystem_quoteconversation';

    /**
     * Prefix of model events names
     *
     * @var string
     */
    protected $_eventPrefix = 'quotesystem_quoteconversation';

    /**
     * Initialize resource model
     *
     * @return void
     */
    protected function _construct()
    {
        $this->_init(\Magetop\Quotesystem\Model\ResourceModel\Quoteconversation ::class);
    }
    /**
     * Return unique ID(s) for each object in system
     *
     * @return array
     */
    public function getIdentities()
    {
        return [self::CACHE_TAG . '_' . $this->getEntityId()];
    }

    /**
     * Get ID
     *
     * @return int|null
     */
    public function getEntityId()
    {
        return $this->getData(self::ENTITYID);
    }
    /**
     * Set ID
     *
     * @param int $id
     * @return \Magetop\Quotesystem\Model\Quotesconversation
     */
    public function setEntityId($id)
    {
        return $this->setData(self::ENTITYID, $id);
    }

    /**
     * Get attachments
     *
     * @return string|null
     */
    public function getAttachments()
    {
        return $this->getData(self::ATTACHMENTS);
    }
    
    /**
     * Set attachments
     *
     * @param string $attachments
     *
     * @return \Magetop\Quotesystem\Api\Data\QuoteInterface
     */
    public function setAttachments($attachments)
    {
        return $this->setData(self::ATTACHMENTS, $attachments);
    }
}
