Method | Description | |
---|---|---|
__construct ( string $outputFormat, array $request = [] ) | ||
disableDataTablePostProcessor ( ) | ||
disableSendHeader ( ) | ||
getResponse ( mixed $value = null, boolean | string $apiModule = false, boolean | string $apiMethod = false ) : mixed | This method processes the data resulting from the API call. | |
getResponseException ( Exceptio\Exception | Throwable $e ) : string | Returns an error $message in the requested $format |
Method | Description | |
---|---|---|
decorateExceptionWithDebugTrace ( Exceptio\Exception | Throwable $e ) : Exception | ||
formatExceptionMessage ( Exceptio\Exception | Throwable $exception ) : string | ||
handleArray ( $array ) | ||
handleDataTable ( Piwik\DataTable\DataTableInterface $datatable ) | ||
sendHeaderIfEnabled ( ) |
public __construct ( string $outputFormat, array $request = [] ) | ||
$outputFormat | string | |
$request | array |
public getResponse ( mixed $value = null, boolean | string $apiModule = false, boolean | string $apiMethod = false ) : mixed | ||
$value | mixed | The initial returned value, before post process. If set to null, success response is returned. |
$apiModule | boolean | string | The API module that was called |
$apiMethod | boolean | string | The API method that was called |
return | mixed | Usually a string, but can still be a PHP data structure if the format requested is 'original' |
public getResponseException ( Exceptio\Exception | Throwable $e ) : string | ||
$e | Exceptio\Exception | Throwable | |
return | string |