I have two question about binary values: one about input and one about output.
A) About input
In the example listing following "The description of the example EchoProcess process might be:" I read:
"imagesInput": {
"title": "Inline Images Value Input",
"description": "This is an example of an image input. In this case,
the input is an array of up to 150 images that might, for example, be a set of
tiles. The oneOf[] conditional is used to indicate the acceptable image content
types; GeoTIFF and JPEG 2000 in this case. Each input image in the input array
can be included inline in the execute request as a base64-encoded string or
referenced using the link.yaml schema. The use of a base64-encoded string is
implied by the specification and does not need to be specified in the definition
of the input.",
Specifically it states: The use of a base64-encoded string is implied by the specification
Also, according to /req/core/process-execute-input-inline-binary:
The service SHALL support binary values encoded as base64-encoded strings.
However I didn't find a statement saying the input binary values must be base64-encoded strings: apparently the server must support (also) base64-encoded strings.
Question: using base64-encoded strings is a client option or is it mandatory?
B) About output
In case of a request where:
- The process description is what is provided for
EchoProcess
- Negotiated execute mode:
sync
- There is no return preference:
Prefer HEADER = none
- There is no request for
media type
- All the following results are returned
by value, not by reference
B.1) Case of single output
- the output requested is only one
- the output requested is
imagesOutput
"imagesOutput": {
"schema": {
"oneOf": [
{
"type": "string",
"contentEncoding": "binary",
"contentMediaType": "image/tiff; application=geotiff"
},
{
"type": "string",
"contentEncoding": "binary",
"contentMediaType": "image/jp2"
}
]
}
},
B.1.1) Single item
- there is only one image to return
Question: the returned "Response Body" should either be: a) a binary value; b) a base64-encoded string ?
B.1.2) Multiple items
- there are two (or more) images to return (i.e. an array, as per
Example 2 — A result encoded as JSON.)
[Side note: I wonder if the definition of imagesOutput should include a "maxOccurs" to allow multiple items.]
Then I understand the returned "Response Body" should represent an array.
I also assume the value of each single image is returned as for the case of B.1.1)
Question: how to delimit the two images of the array in the "Response Body"?
B.2) Case of multiple output
- the output requested are two:
imagesOutput (defined above in B1) ), stringOutput
I understand the "Response Body" sholud be something like:
{
"stringOutput": "Value1",
"imagesOutput": { "value": <image_value>, "encoding": <content_encoding>, "mediaType": <media_type> }
}
Question: what should be <content_encoding> ? [I understand <image_value> will then be coded accordingly]
I have two question about binary values: one about input and one about output.
A) About input
In the example listing following "
The description of the example EchoProcess process might be:" I read:Specifically it states: The use of a base64-encoded string is implied by the specification
Also, according to
/req/core/process-execute-input-inline-binary:The service SHALL support binary values encoded as base64-encoded strings.However I didn't find a statement saying the input binary values must be base64-encoded strings: apparently the server must support (also) base64-encoded strings.
Question: using base64-encoded strings is a client option or is it mandatory?
B) About output
In case of a request where:
EchoProcesssyncPrefer HEADER = nonemedia typeby value, notby referenceB.1) Case of single output
imagesOutputB.1.1) Single item
Question: the returned "
Response Body" should either be: a) a binary value; b) a base64-encoded string ?B.1.2) Multiple items
Example 2 — A result encoded as JSON.)[Side note: I wonder if the definition of
imagesOutputshould include a "maxOccurs" to allow multiple items.]Then I understand the returned "
Response Body" should represent an array.I also assume the value of each single image is returned as for the case of B.1.1)
Question: how to delimit the two images of the array in the "
Response Body"?B.2) Case of multiple output
imagesOutput(defined above in B1) ),stringOutputI understand the "
Response Body" sholud be something like:Question: what should be
<content_encoding>? [I understand<image_value>will then be coded accordingly]