PHP Class Api\V1\Engine\Api

Deprecation:
Inheritance: extends KernelLoader, implements ApplicationInterface
Afficher le fichier Open project: forkcms/forkcms Class Usage Examples

Protected Properties

Свойство Type Description
$content string

Méthodes publiques

Méthode Description
display ( ) : Response
initialize ( ) Initializes the entire API; extract class+method from the request, call, and output.
isAuthorized ( ) : boolean Default authentication
isValidRequestMethod ( string $method ) : boolean This is called in backend/modules//engine/api.php to limit certain calls to a given request method.
output ( integer $statusCode, array $data = null ) : boolean Output the return

Private Methods

Méthode Description
arrayToXML ( mixed &$input, string $key, DOMElement $XML ) Callback-method for elements in the return-array
getHeaderMessage ( $statusCode ) : string Get the relevant HTTP status message
outputJSON ( integer $statusCode, array $data = null ) Output as JSON
outputXML ( integer $statusCode, array $data = null ) Output as XML

Method Details

display() public méthode

public display ( ) : Response
Résultat Symfony\Component\HttpFoundation\Response

initialize() public méthode

This method exists because the service container needs to be set before the rest of API functionality gets loaded.
public initialize ( )

isAuthorized() public static méthode

Default authentication
public static isAuthorized ( ) : boolean
Résultat boolean

isValidRequestMethod() public static méthode

This is called in backend/modules//engine/api.php to limit certain calls to a given request method.
public static isValidRequestMethod ( string $method ) : boolean
$method string
Résultat boolean

output() public static méthode

Output the return
public static output ( integer $statusCode, array $data = null ) : boolean
$statusCode integer The status code.
$data array The data to return.
Résultat boolean

Property Details

$content protected_oe static_oe property

protected static string $content
Résultat string