GetTrait
Trait GetTrait
Table of Contents
Methods
- downloadTemplate() : string
- Download the binary data of a template from template storage
- getAccountSettings() : array<string|int, mixed>
- Return an array of properties for the ReportingCloud account
- getApiKeys() : array<string|int, mixed>
- Return an associative array of API keys associated with the Reporting Cloud account
- getAvailableDictionaries() : array<string|int, mixed>
- Return an array of available dictionaries on the Reporting Cloud service
- getFontList() : array<string|int, mixed>
- Return an array of available fonts on the Reporting Cloud service
- getProofingSuggestions() : array<string|int, mixed>
- Return an array of suggestions for a misspelled word
- getTemplateCount() : int
- Return the number of templates in template storage
- getTemplateInfo() : array<string|int, mixed>
- Return an array of merge blocks and merge fields in a template file in template storage
- getTemplateList() : array<string|int, mixed>
- Return an array of properties for the templates in template storage
- getTemplatePageCount() : int
- Return the number of pages in a template in template storage
- getTemplateThumbnails() : array<string|int, mixed>
- Generate a thumbnail image per page of specified template in template storage.
- proofingCheck() : array<string|int, mixed>
- Check a corpus of text for spelling errors.
- templateExists() : bool
- Return true, if the template exists in template storage
- buildPropertyMapArray() : array<string|int, mixed>
- Using the passed propertyMap, recursively build array
- request() : ResponseInterface
- Request the URI with options
- uri() : string
- Construct URI with version number
- get() : mixed
- Execute a GET request via REST client
Methods
downloadTemplate()
Download the binary data of a template from template storage
public
downloadTemplate(string $templateName) : string
Parameters
- $templateName : string
-
Template name
Return values
stringgetAccountSettings()
Return an array of properties for the ReportingCloud account
public
getAccountSettings() : array<string|int, mixed>
Return values
array<string|int, mixed>getApiKeys()
Return an associative array of API keys associated with the Reporting Cloud account
public
getApiKeys() : array<string|int, mixed>
Return values
array<string|int, mixed>getAvailableDictionaries()
Return an array of available dictionaries on the Reporting Cloud service
public
getAvailableDictionaries() : array<string|int, mixed>
Return values
array<string|int, mixed>getFontList()
Return an array of available fonts on the Reporting Cloud service
public
getFontList() : array<string|int, mixed>
Return values
array<string|int, mixed>getProofingSuggestions()
Return an array of suggestions for a misspelled word
public
getProofingSuggestions(string $word, string $language[, int $max = 10 ]) : array<string|int, mixed>
Parameters
- $word : string
-
Word that should be spell checked
- $language : string
-
Language of specified text
- $max : int = 10
-
Maximum number of suggestions to return
Return values
array<string|int, mixed>getTemplateCount()
Return the number of templates in template storage
public
getTemplateCount() : int
Return values
intgetTemplateInfo()
Return an array of merge blocks and merge fields in a template file in template storage
public
getTemplateInfo(string $templateName) : array<string|int, mixed>
Parameters
- $templateName : string
-
Template name
Return values
array<string|int, mixed>getTemplateList()
Return an array of properties for the templates in template storage
public
getTemplateList() : array<string|int, mixed>
Return values
array<string|int, mixed>getTemplatePageCount()
Return the number of pages in a template in template storage
public
getTemplatePageCount(string $templateName) : int
Parameters
- $templateName : string
-
Template name
Return values
intgetTemplateThumbnails()
Generate a thumbnail image per page of specified template in template storage.
public
getTemplateThumbnails(string $templateName, int $zoomFactor, int $fromPage, int $toPage, string $imageFormat) : array<string|int, mixed>
Return an array of binary data with each record containing one thumbnail.
Parameters
- $templateName : string
-
Template name
- $zoomFactor : int
-
Zoom factor
- $fromPage : int
-
From page
- $toPage : int
-
To page
- $imageFormat : string
-
Image format
Return values
array<string|int, mixed>proofingCheck()
Check a corpus of text for spelling errors.
public
proofingCheck(string $text, string $language) : array<string|int, mixed>
Return an array of misspelled words, if spelling errors are found in the corpus of text.
Return an empty array, if no misspelled words are found in the corpus of text.
Parameters
- $text : string
-
Corpus of text that should be spell checked
- $language : string
-
Language of specified text
Return values
array<string|int, mixed>templateExists()
Return true, if the template exists in template storage
public
templateExists(string $templateName) : bool
Parameters
- $templateName : string
-
Template name
Return values
boolbuildPropertyMapArray()
Using the passed propertyMap, recursively build array
protected
abstract buildPropertyMapArray(array<string|int, mixed> $array, AbstractPropertyMap $propertyMap) : array<string|int, mixed>
Parameters
- $array : array<string|int, mixed>
-
Array
- $propertyMap : AbstractPropertyMap
-
PropertyMap
Return values
array<string|int, mixed>request()
Request the URI with options
protected
abstract request(string $method, string $uri, array<string|int, mixed> $options) : ResponseInterface
Parameters
- $method : string
-
HTTP method
- $uri : string
-
URI
- $options : array<string|int, mixed>
-
Options
Return values
ResponseInterfaceuri()
Construct URI with version number
protected
abstract uri(string $uri) : string
Parameters
- $uri : string
-
URI
Return values
stringget()
Execute a GET request via REST client
private
get(string $uri[, array<string|int, mixed> $query = [] ][, mixed $json = '' ][, int $statusCode = 0 ]) : mixed
Parameters
- $uri : string
-
URI
- $query : array<string|int, mixed> = []
-
Query
- $json : mixed = ''
-
JSON
- $statusCode : int = 0
-
Required HTTP status code for response