<?php
namespace ModulesAbstract\ElectronicInvoice\UBL21Structure;

class AbstractPeppolElementWithOneValue extends AbstractPeppolElement
{
	/**
	 * the tag content, 0..1, optional tag
	 *
	 * The tag content, used when a tag also has attributes
	 * @var string
	 */
	public $value = null;

	public function getAttributes()
	{
		$members = array_keys(get_object_vars($this));
		$members = array_filter($members, function ($k) {
			return $k!='value';
		});

		return array_combine($members, $members);
	}

	public function getChilds()
	{
		return ['value' => null];
	}
}
