ComplexObsHandler interface needs to support complex data encoded as text, this makes it possible to submit complex Obs data via text based transfer channels. A use case for this is to be able to submit a complex Obs via REST which only accepts JSON and XML text.
- Add the new method below to ComplexObsHandler interface
- The data is assumed to be uuencoded, Java has the UUDecoder class that you can use.
- Update the handlers in core i.e ImageHandler, MediaHandler and BinaryDataHandler to implement this method which will decode and convert the passed in text data to its actual representation, the BinaryDataHandler handler handles data submitted as an InputStream or a byte array but we can skip dealing with InputStreams for this ticket and assume the encoded text has to be converted to a byte array. You could possibly introduce a base class that implements setComplexData(Obs obs, Object data) that is extended by these handlers to centralize the decoding logic.