protected function isParameterExistsInResourceProperties($p, $resourceName = '', $resourceProperties)
	{
		// Reference
		if (isset($p['$ref'])) {
			$parameter = $this->resolveReference($p['$ref'])['target'];
		} else {
			$parameter = $p;
		}
		
		// Check if it's a resource property
		if (count($resourceProperties) > 0) {
			// Resource Id pattern
			$pattern = '/(\w+)Id$/';
			if (preg_match($pattern, $parameter['name'])) {
				$resourcePropertyToMatch = ucfirst(substr($parameter['name'], 0, strlen($parameter['name']) - 2));
				$snakeCaseResourcePropertyToMatch = strtolower(preg_replace('/(?<!^)[A-Z]/', '_$0', $resourcePropertyToMatch));
				foreach ($resourceProperties as $resourceProperty) {
					if ($resourceProperty['name'] == $snakeCaseResourcePropertyToMatch) {
						return true;
					}
				}
			}
		}
		
		// This resource Id ?
		
		// Resource Id pattern
		$pattern = '/(\w+)Id$/';
		
		if (preg_match($pattern, $parameter['name'])) {
			$resourcePropertyToMatch = ucfirst(substr($parameter['name'], 0, strlen($parameter['name']) - 2));
			if ($resourceName == $resourcePropertyToMatch) {
				return true;
			}
		}
		
		// This resource composite key or foreign key ?
		
		$snakeCaseParameterName = strtolower(preg_replace('/(?<!^)[A-Z]/', '_$0', $parameter['name']));
		foreach ($resourceProperties as $resourceProperty) {
			if ($resourceProperty['name'] == $snakeCaseParameterName) {
				return true;
			}
		}
		
		return false;
	}
protected function isParameterExistsInResourceProperties($p, $resourceName = '', $resourceProperties)
	{
		// Reference
		if (isset($p['$ref'])) {
			$parameter = $this->resolveReference($p['$ref'])['target'];
		} else {
			$parameter = $p;
		}
		
		// Check if it's a resource property
		if (count($resourceProperties) > 0) {
			// Resource Id pattern
			$pattern = '/(\w+)Id$/';
			if (preg_match($pattern, $parameter['name'])) {
				$resourcePropertyToMatch = ucfirst(substr($parameter['name'], 0, strlen($parameter['name']) - 2));
				$snakeCaseResourcePropertyToMatch = strtolower(preg_replace('/(?<!^)[A-Z]/', '_$0', $resourcePropertyToMatch));
				foreach ($resourceProperties as $resourceProperty) {
					if ($resourceProperty['name'] == $snakeCaseResourcePropertyToMatch) {
						return true;
					}
				}
			}
		}
		
		// This resource Id ?
		
		// Resource Id pattern
		$pattern = '/(\w+)Id$/';
		
		if (preg_match($pattern, $parameter['name'])) {
			$resourcePropertyToMatch = ucfirst(substr($parameter['name'], 0, strlen($parameter['name']) - 2));
			if ($resourceName == $resourcePropertyToMatch) {
				return true;
			}
		}
		
		// This resource composite key or foreign key ?
		
		$snakeCaseParameterName = strtolower(preg_replace('/(?<!^)[A-Z]/', '_$0', $parameter['name']));
		foreach ($resourceProperties as $resourceProperty) {
			if ($resourceProperty['name'] == $snakeCaseParameterName) {
				return true;
			}
		}
		
		return false;
	}
protected function isParameterExistsInResourceProperties ( $ p , $ resourceName = '' , $ resourceProperties ) { // Reference
 if ( isset ( $ p [ '$ref' ] ) ) { $ parameter = $ this -> resolveReference ( $ p [ '$ref' ] ) [ 'target' ] ; } else { $ parameter = $ p ; } // Check if it's a resource property
 if ( count ( $ resourceProperties ) > 0 ) { // Resource Id pattern
 $ pattern = '/(\w+)Id$/' ; if ( preg_match ( $ pattern , $ parameter [ 'name' ] ) ) { $ resourcePropertyToMatch = ucfirst ( substr ( $ parameter [ 'name' ] , 0 , strlen ( $ parameter [ 'name' ] ) - 2 ) ) ; $ snakeCaseResourcePropertyToMatch = strtolower ( preg_replace ( '/(?<!^)[A-Z]/' , '_$0' , $ resourcePropertyToMatch ) ) ; foreach ( $ resourceProperties as $ resourceProperty ) { if ( $ resourceProperty [ 'name' ] == $ snakeCaseResourcePropertyToMatch ) { return true ; } } } } // This resource Id ?
 // Resource Id pattern
 $ pattern = '/(\w+)Id$/' ; if ( preg_match ( $ pattern , $ parameter [ 'name' ] ) ) { $ resourcePropertyToMatch = ucfirst ( substr ( $ parameter [ 'name' ] , 0 , strlen ( $ parameter [ 'name' ] ) - 2 ) ) ; if ( $ resourceName == $ resourcePropertyToMatch ) { return true ; } } // This resource composite key or foreign key ?
 $ snakeCaseParameterName = strtolower ( preg_replace ( '/(?<!^)[A-Z]/' , '_$0' , $ parameter [ 'name' ] ) ) ; foreach ( $ resourceProperties as $ resourceProperty ) { if ( $ resourceProperty [ 'name' ] == $ snakeCaseParameterName ) { return true ; } } return false ; }
Check if a parameter exists in the resource properties

@param mixed $p Parameter
@param string $resourceName Resource name
@param mixed[] $resourceProperties Properties
@return boolean
Check if a parameter exists in the resource properties