• Модуль: disk
  • Путь к файлу: ~/bitrix/modules/disk/lib/rest/entity/storage.php
  • Класс: BitrixDiskRestEntityStorage
  • Вызов: Storage::getFieldsForMap
public function getFieldsForMap()
{
	return array(
		'ENTITY_TYPE' => array(
			'IN' => function($externalValue){
				switch($externalValue)
				{
					case 'user':
						return ProxyTypeUser::className();
					case 'group':
						return ProxyTypeGroup::className();
					case 'common':
						return ProxyTypeCommon::className();
				}

				return null;
			},
			'OUT' => function($internalValue){
				switch($internalValue)
				{
					case ProxyTypeUser::className():
						return 'user';
					case ProxyTypeGroup::className():
						return 'group';
					case ProxyTypeCommon::className():
						return 'common';
					case ProxyTypeRestApp::className():
						return 'restapp';
				}

				return null;
			}
		)
	);
}