@param string $methodName

@return bool
193918
protected static function isAjaxMethod($methodName)
    {
        $suffixLength = strlen(self::AJAX_METHOD_NAME_SUFFIX);

        return strlen($methodName) > $suffixLength
            && self::AJAX_METHOD_NAME_SUFFIX === substr($methodName, -1 * $suffixLength);
    }
992105
private function checkVisibilityPublic(string &$methodName): bool
    {
        if (true === $this->reflectionsMethods[$methodName]->isPublic()) {
            //It's a public method, do like if there is no method
            return true;
        }

        return false;
    }
601210
protected function isEventHandlerExclusion($className, $methodName, array $methodParams)
    {
        if (strpos($className, 'EventHandler') === false) {
            // Not EventHandler class.
            return false;
        }

        return substr($methodName, 0, 2) == 'On' && count($methodParams) === 1 && $methodParams[0]['name'] === '$event';
    }
766155
public function getProperty(string $methodName): ?string
    {
        $pattern = implode('|', array_merge(self::ACCESSOR_PREFIXES, self::MUTATOR_PREFIXES));

        if (preg_match('/^('.$pattern.')(.+)$/i', $methodName, $matches)) {
            return $matches[2];
        }

        return null;
    }
543560
private function getClassName($methodName)
    {
        $parts = explode($this->separator, $methodName);
        array_pop($parts); // Remove method

        foreach ($parts as &$part) {
            $part = ucwords($part);
        }

        return $this->namespace . join('\\', $parts);
    }
166452
public function callMethod($methodName, array $parameters = array())
	{
		$this->_status = null;
		$this->_response = null;
		$this->_rawResponse = null;
		$this->_error = null;

		$parameters = array_values($parameters);

		$this->_id++;

		$input = json_encode(array(
			'method' => $methodName,
			'params' => $parameters,
			'id' => $this->_id
		));

		$curlResource = curl_init("{$this->_protocol}://{$this->_user}:{$this->_password}@{$this->_host}:{$this->_port}");
		$curlOptions = array(
			CURLOPT_RETURNTRANSFER => true,
			CURLOPT_FOLLOWLOCATION => true,
			CURLOPT_HTTPHEADER => array("Content-type: application/json"),
			CURLOPT_POST => true,
			CURLOPT_POSTFIELDS => $input,
		);

		if ($this->_protocol == 'https')
		{
			if ($this->_cert != null)
			{
				$curlOptions[CURLOPT_CAINFO] = $this->_cert;
				$curlOptions[CURLOPT_CAPATH] = dirname($this->_cert);
				$curlOptions[CURLOPT_SSL_VERIFYPEER] = true;
				$curlOptions[CURLOPT_SSL_VERIFYHOST] = true;
			}
			else
			{
				$curlOptions[CURLOPT_SSL_VERIFYPEER] = false;
				$curlOptions[CURLOPT_SSL_VERIFYHOST] = false;
			}
		}

		curl_setopt_array($curlResource, $curlOptions);

		$this->_rawResponse = curl_exec($curlResource);

		$this->_response = json_decode($this->_rawResponse,
			$this->getOption(self::OPTION_RESPONSE_FORMAT, self::RESPONSE_ASSOC_ARRAY) == self::RESPONSE_ASSOC_ARRAY);

		$this->_status = curl_getinfo($curlResource, CURLINFO_HTTP_CODE);

		$curlError = curl_error($curlResource);

		curl_close($curlResource);

		if ($curlError)
		{
			$this->_error = $curlError;

			return false;
		}

		if ($this->_response['error'])
		{
			$this->_error = $this->_response['error']['message'];
			$this->_errorCode = $this->_response['error']['code'];
		}
		else if ($this->_status != 200)
		{
			switch ($this->_status)
			{
				case 400:
					$this->_error = "HTTP_BAD_REQUEST";
					break;
				case 401:
					$this->_error = "HTTP_UNAUTHORIZED";
					break;
				case 403:
					$this->_error = "HTTP_FORBIDDEN";
					break;
				case 404:
					$this->_error = "HTTP_NOT_FOUND";
					break;
				default:
					throw new ChaincoinException("An unexpected http response code was encountered!");
			}
		}

		if ($this->_error)
		{
			return false;
		}

		return $this->_response['result'];
	}
993571
public function setReplyMethod($methodName)
    {
        if (!preg_match('#^[/?]#', $methodName)) {
            $this->_targetUri = rtrim($this->_targetUri, '/') . '/';
        }
        $this->_targetUri = $this->_targetUri . $methodName;
        return $this;
    }
1056994
public function canCallMethod($methodName, $options)
    {
        return (null !== ($options = $this->getMethodParameters($methodName, $options, false)));
    }
852806
public function call($methodName = null)
    {
        $this->setMethod($methodName);

        $curl = $this->getCurl();
        $curl->setParameters($this->getParameters());

        $this->log($this->getParameters(), 'Request to PayPal');

        $response = $curl->execute();

        $this->log($response, 'Response from PayPal');

        $this->validateResponse($response);

        return $response;
    }
163662
protected function isMethodDeprecated(MethodNode $method)
    {
        return (bool)preg_match($this->regexp, $method->getNode()->getDocComment());
    }
899154
protected static function translatePath($methodName)
    {
        $methodName = preg_replace('/Action$/', '', $methodName);
        return '/'.preg_replace_callback('/[A-Z]/', function ($matches) {
            return '/'.strtolower($matches[0]);
        }, $methodName);
    }
1253848
private static function deprecated($methodName)
    {
        $message = 'Use of ' . $methodName . ' and the whole ShopgateConfigOld class is deprecated.';
        trigger_error($message, E_USER_DEPRECATED);
        ShopgateLogger::getInstance()->log($message);
    }
372844
public function isMethodPublic($className, $methodName)
    {
        $className = $this->prepareClassReflectionForUsage($className);
        return (isset($this->classReflectionData[$className][self::DATA_CLASS_METHODS][$methodName][self::DATA_METHOD_VISIBILITY]) && $this->classReflectionData[$className][self::DATA_CLASS_METHODS][$methodName][self::DATA_METHOD_VISIBILITY] === self::VISIBILITY_PUBLIC);
    }
622380
protected function hasPropelQueryAllocationExpression(MethodNode $method): bool
    {
        foreach ($method->findChildrenOfType('ClassOrInterfaceReference') as $referenceNode) {
            $isQueryReference = (bool)strpos($referenceNode->getName(), 'Query');

            if (!$isQueryReference) {
                continue;
            }

            $methodPostfixChild = $method->getFirstChildOfType('MethodPostfix');

            if ($methodPostfixChild !== null && $methodPostfixChild->getName() === 'create') {
                return true;
            }
        }

        return false;
    }
912358
public function invoke($methodName, array $arguments = [])
    {
        $this->trigger(self::EVENT_BEFORE_METHOD);
        $result = call_user_func_array([$this->o, $methodName], $arguments);
        $this->trigger(self::EVENT_AFTER_METHOD);
        return $result;
    }
990009
public function matchesMethod($className, $methodName): bool
    {
        $this->initialize();

        $methodIdentifier = strtolower($className . '->' . $methodName);
        if (isset(static::$methodPermissions[$methodIdentifier][$this->getCacheEntryIdentifier()])) {
            return true;
        }

        return false;
    }
801763
protected static function extractAjaxMethod($methodName)
    {
        $suffixLength = strlen(self::AJAX_METHOD_NAME_SUFFIX);

        return substr(
            $methodName,
            0,
            strlen($methodName) - $suffixLength
        );
    }