1

I've a DataSnap REST method returning files as TStream. The client side is Objective-C code on iOS, JavaScript code, and Delphi code. I compiled the server side with Delphi Sydney 10.4.1, upgrading from Delphi XE3. Testing the new version, I realized the stream response format now is a JSON Array, and no more a content stream of the response. I can get a content stream with a client-side parameter:

http://host:port/datasnap/rest/[Class]/[Method]/?json=false

But this require to update the client software too, and I want to pospone this update and distribute updates progressively. Is there a way to force DataSnap REST server to apply the "?json=false" behaviour for a specific method call? Or for any method involving TStream response? The TWebModule1.DSHTTPWebDispatcher1FormatResult let me manage the result val but I need not to change the json response, but to have a content stream instead.

0 Answers0