You are here

public function Handler::getMethod in JSON-RPC 2.x

Same name and namespace in other branches
  1. 8 src/Handler.php \Drupal\jsonrpc\Handler::getMethod()

Gets a method definition by method name.

Parameters

string $name: The method name for which support should be determined.

Return value

\Drupal\jsonrpc\MethodInterface|null The method definition.

Overrides HandlerInterface::getMethod

2 calls to Handler::getMethod()
Handler::doExecution in src/Handler.php
Gets an anonymous function which executes the RPC method.
Handler::supportsMethod in src/Handler.php
Whether the given method is supported.

File

src/Handler.php, line 99

Class

Handler
Manages all the JSON-RPC business logic.

Namespace

Drupal\jsonrpc

Code

public function getMethod($name) {
  return $this->methodManager
    ->getDefinition($name, FALSE);
}