private function toInstanceDescriptor($instanceNames) {
		if ($instanceNames === null) {
			return null;
		}
		if (is_array($instanceNames)) {
			$moufManager = $this->moufManager;
			return self::array_map_deep($instanceNames, function($instanceName) use ($moufManager) {
				if ($instanceName != null) {
					return $moufManager->getInstanceDescriptor($instanceName);
				} else {
					return null;
				}
			});
			/*$arrayOfDescriptors = array();
			foreach ($instanceNames as $key=>$instanceName) {
				if ($instanceName != null) {
					$arrayOfDescriptors[$key] = $this->moufManager->getInstanceDescriptor($instanceName);
				} else {
					$arrayOfDescriptors[$key] = null;
				}
			}
			return $arrayOfDescriptors;*/
		} else {
			return $this->moufManager->getInstanceDescriptor($instanceNames);
		}
		
	}