core/model/modx/jsonrpc/modjsonrpcresponse.class.php

Show: inherited
Table of Contents

Package
modx  
Subpackage
jsonrpc  

\modJSONRPCResponse

Package: modx\jsonrpc

Extends modXMLRPCResponse to support servicing JSON-RPC client requests.

Includes functions to manipluate header data, such as status codes, as well as manipulating the response body.

Parent(s)
\modXMLRPCResponse < \modResponse

Properties

Propertypublicstring  $body= 'null'
inherited

The body of this response

Inherited from: \modResponse::$$body\modXMLRPCResponse::$$body
Default valuenullDetails
Type
string
Inherited_from
\modResponse::$$body  
Inherited_from
\modXMLRPCResponse::$$body  
Propertypublic\modContentType  $contentType= 'null'
inherited

The current content type on the resource

Inherited from: \modResponse::$$contentType\modXMLRPCResponse::$$contentType
Default valuenullDetails
Type
\modContentType
Inherited_from
\modResponse::$$contentType  
Inherited_from
\modXMLRPCResponse::$$contentType  
Propertypublicstring  $header= 'null'
inherited

The HTTP header for this Response

Inherited from: \modResponse::$$header\modXMLRPCResponse::$$header
Default valuenullDetails
Type
string
Inherited_from
\modResponse::$$header  
Inherited_from
\modXMLRPCResponse::$$header  
Propertypublic\modX  $modx= 'null'
inherited

A reference to the modX instance

Inherited from: \modResponse::$$modx\modXMLRPCResponse::$$modx
Default valuenullDetails
Type
\modX
Inherited_from
\modResponse::$$modx  
Inherited_from
\modXMLRPCResponse::$$modx  
Propertypublic\xmlrpc_server  $server= 'null'
inherited

The XML-RPC server attached to this response

Inherited from: \modXMLRPCResponse::$$server
Default valuenullDetails
Type
\xmlrpc_server
Access
public  
Inherited_from
\modXMLRPCResponse::$$server  
Propertypublicarray  $services= 'array ()'
inherited

A collection of services attached to this response

Inherited from: \modXMLRPCResponse::$$services
Default valuearray ()Details
Type
array
Access
public  
Inherited_from
\modXMLRPCResponse::$$services  

Methods

methodpublic__construct( \modX $modx ) : void
Parameters
Name Type Description
$modx \modX

A reference to the modX instance

methodpubliccheckPreview( ) : boolean
inherited

Checks to see if the preview parameter is set.

Inherited from: \modResponse::checkPreview()\modXMLRPCResponse::checkPreview()
Returns
Type Description
boolean
methodpublicgetServer( bool $execute = false ) : bool

Load the JSON-RPC server

Parameters
Name Type Description
$execute bool

Execute the server process

Returns
Type Description
bool True if the server was successfully loaded
methodpublicoutputContent( array $options = array() ) : void

Output the content of this response

Parameters
Name Type Description
$options array

An array of options for the output

methodpublicregisterService( string $key, string $signature ) : void
inherited

Registers a service to this response

Inherited from: \modXMLRPCResponse::registerService()
Parameters
Name Type Description
$key string

The name of the service

$signature string

The signature of the service

Details
Access
public  
methodpublicsendRedirect( string $url, array | boolean $options = false, string $type = '', string $responseCode = '' ) : void | boolean
inherited

Sends a redirect to the specified URL using the specified method.

Inherited from: \modResponse::sendRedirect()\modXMLRPCResponse::sendRedirect()

Valid $type values include: REDIRECT_REFRESH Uses the header refresh method REDIRECT_META Sends a a META HTTP-EQUIV="Refresh" tag to the output REDIRECT_HEADER Uses the header location method

REDIRECT_HEADER is the default.

Parameters
Name Type Description
$url string

The URL to redirect the client browser to.

$options array | boolean

An array of options for the redirect OR indicates if redirect attempts should be counted and limited to 3 (latter is deprecated usage; use count_attempts in options array).

$type string

The type of redirection to attempt (deprecated, use type in options array).

$responseCode string

The type of HTTP response code HEADER to send for the redirect (deprecated, use responseCode in options array)

Returns
Type Description
void | boolean
methodpublicunregisterService( string $key ) : void
inherited

Unregisters a service from this response

Inherited from: \modXMLRPCResponse::unregisterService()
Parameters
Name Type Description
$key string

The name of the service

Details
Access
public  
Documentation was generated by DocBlox 0.18.1.