PHP Class Prado\Web\Services\TRpcServer

TRpcServer is a class TRpcServer is the base class used to creare a server to be used in conjunction with {@link TRpcService}. The role of TRpcServer is to be an intermediate, moving data between the service and the provider. This base class should suit the most common needs, but can be sublassed for logging and debugging purposes, or to filter and modify the request/response on the fly.
Since: 3.2
Author: Robin J. Rogge ([email protected])
Inheritance: extends Prado\TModule
Afficher le fichier Open project: pradosoft/prado

Protected Properties

Свойство Type Description
$handler instance

Méthodes publiques

Méthode Description
__construct ( TRpcProtocol $protocolHandler ) Constructor
addRpcMethod ( string $methodName, array $methodDetails ) Registers the method in the protocol handler
getPayload ( ) : string Retrieves the request payload
processRequest ( ) : string Passes the request payload to the protocol handler and returns the result

Method Details

__construct() public méthode

Constructor
public __construct ( TRpcProtocol $protocolHandler )
$protocolHandler TRpcProtocol instance

addRpcMethod() public méthode

Registers the method in the protocol handler
public addRpcMethod ( string $methodName, array $methodDetails )
$methodName string
$methodDetails array

getPayload() public méthode

Retrieves the request payload
public getPayload ( ) : string
Résultat string request payload

processRequest() public méthode

Passes the request payload to the protocol handler and returns the result
public processRequest ( ) : string
Résultat string rpc response

Property Details

$handler protected_oe property

instance
protected $handler