BrightSign Object Reference Manual (FW 5.1) User Manual

Page 30

Advertising
background image

22

searchRequest = CreateObject("roUrlTransfer")
searchRequest.SetURL("

http://api.example.com/services/rest/getPhotos"

)

response = ParseJson(searchRequest.GetToString())
For Each photo In response.photos

GetImage(photo.title, photo.url)

End For

FormatJson(json As roAssociativeArray, flags As Integer) As String: Converts an associative
array to a JSON string (i.e. formatted according to the RFC4627 standard). The following are supported data types:
Boolean, Integer, Float, String, roArray, and roAssociativeArray. If the

flags parameter is set to 0 or not specified,

non-ASCII characters are escaped in the output string as “\uXXXX”, where “XXXX” is the hexadecimal
representation of the Unicode character value. If the

flags parameter is set to 1, non-ASCII characters are not

escaped. If arrays or associative arrays are nested more than 256 levels deep, an error will occur. If an error
occurs, an empty string will be returned.

Advertising