<?php
namespace ModulesAbstract\PluginReports\Report\Model\Gatherer\ExportData;

/**
 * Helper class for exported cashbook xml files
 * @author FlorinRusu
 */
class Cashbook extends AbstractExportDataFile
{
	public function getDate()
	{
		return (String)$this->docDate;
	}

	/**
	 * Returns the partner type based on the xml client type
	 * @return null
	 */
	public function getPartnerType()
	{
		return null;
	}

	/**
	 * Returns an associative array of xml information based on the client type
	 * @return NULL[]
	 */
	public function getPartnerDetails()
	{
		return [];
	}


	/**
	 *
	 * {@inheritDoc}
	 * @see \ModulesAbstract\PluginReports\Report\Model\Gatherer\ExportData\AbstractExportDataFile::isVoid()
	 */
	public function isVoid()
	{
		return (((String)$this['operation'] == 'void') or ((String)$this['operation'] == 'unconfirm'));
	}

	/**
	 *
	 * {@inheritDoc}
	 * @see \ModulesAbstract\PluginReports\Report\Model\Gatherer\ExportData\AbstractExportDataFile::getVoidDate()
	 */
	public function getVoidDate()
	{
		return $this->getExportDate();
	}

	/**
	 *
	 * {@inheritDoc}
	 * @see \ModulesAbstract\PluginReports\Report\Model\Gatherer\ExportData\AbstractExportDataFile::isConfirmed()
	 */
	public function isIssue()
	{
		return (((String)$this['operation'] == 'issue') or ((String)$this['operation'] == 'confirm'));

	}

	/**
	 *
	 * {@inheritDoc}
	 * @see \ModulesAbstract\PluginReports\Report\Model\Gatherer\ExportData\AbstractExportDataFile::getIssueDate()
	 */
	public function getIssueDate()
	{
		return $this->getDate();
	}

	/**
	 *
	 * {@inheritDoc}
	 * @see \ModulesAbstract\PluginReports\Report\Model\Gatherer\ExportData\AbstractExportDataFile::isCoreDocument()
	 */
	public function isCoreDocument()
	{
		return false;
	}

	/**
	 *
	 * {@inheritDoc}
	 * @see \ModulesAbstract\PluginReports\Report\Model\Gatherer\ExportData\AbstractExportDataFile::isCashbookDocument()
	 */
	public function isCashbookDocument()
	{
		return true;
	}

	/**
	 *
	 * {@inheritDoc}
	 * @see \ModulesAbstract\PluginReports\Report\Model\Gatherer\ExportData\AbstractExportDataFile::isImportedDocument()
	 */
	public function isImportedDocument()
	{
		return false;
	}


}
