Your IP : 216.73.216.86


Current Path : /var/www/homesaver/www/bitrix/modules/location/lib/entity/location/
Upload File :
Current File : /var/www/homesaver/www/bitrix/modules/location/lib/entity/location/fieldcollection.php

<?php

namespace Bitrix\Location\Entity\Location;

use Bitrix\Main\ArgumentTypeException;

/**
 * Class FieldCollection
 * @package Bitrix\Location\Entity\Location
 * @internal
 */
final class FieldCollection extends \Bitrix\Location\Entity\Generic\FieldCollection
{
	/** @var Field[] */
	protected $items = [];

	public function addItem($field): int
	{
		if(!($field instanceof Field))
		{
			throw new ArgumentTypeException('field must be the instance of Field');
		}

		return parent::addItem($field);
	}
}