Jump to content

Leaderboard


Popular Content

Showing content with the highest reputation on 12/18/18 in Posts

  1. I just now had the need to transmit GPS (WGS 84) coordinates from one program to another. First, I simply copied longitude and latitude separately using the clipboard, which works fine but is really time consuming when you have to do that very often. I… https://blog.dummzeuch.de/2018/12/18/register-an-use-a-custom-clipboard-format-in-delphi/
  2. https://twitter.com/EmbarcaderoTech/status/1074771501327548416
  3. Sherlock

    December 2018 IDE Patch for 10.3

    https://cc.embarcadero.com/item/30870 Clearly the more, um, agreeable source.
  4. My advice: keep your permissioning as simple as possible. Flexible permissioning is a rich source of challenges 😛
  5. Günther Schoch

    Unresponsive IDE and massive memory leaks with RIO

    We have reported similar issues already middle of Sept https://quality.embarcadero.com/browse/RSP-21972 https://quality.embarcadero.com/browse/RSP-22289 it's reproduced by EMBT but nothing happened until now. The fact is that EMBT just has not included the TDirectoryCache of the fixpack. This is a show stopper on our side as the IDE fully blocks during the work.
  6. Andrea Magni

    MARS now supports Delphi 10.3 Rio :-)

    Ciao Alberto, thanks for the kind words and I hope you'll enjoy MARS. Feel free to ask questions here or open issues on GitHub if you run into troubles. MARS is a library suitable for creating REST Server projects and also has a client library to build REST Client projects. You can use them independently one from the other (this means MARS REST servers can be 100% Delphi agnostics and this also stands for the Client library that can consume any REST service out there) or use them together and get some Delphi-to-Delphi specific advantages (like some FireDAC integrations). Installation instructions are available here: https://github.com/andrea-magni/MARS/blob/master/docs/Installation.md Let me know if you need help or if you have questions. Sincerely,
  7. Andrea Magni

    Custom media type

    Apart from the registration order, you can define a higher affinity of your writer in order to supersede the standard ones. Just switch the value returned by the affinity function in the RegisterWriter call from TMARSMessageBodyRegistry.AFFINITY_MEDIUM to TMARSMessageBodyRegistry.AFFINITY_HIGH and your writer will have a priority over the standard record writer. I would then write the WriteTo implementation like this: procedure TScimPlusJSONWriter.WriteTo(const AValue: TValue; const AMediaType: TMediaType; AOutputStream: TStream; const AActivation: IMARSActivation); var LType: TRttiType; begin LType := AActivation.MethodReturnType; if not Assigned(LType) then Exit; // procedure? if LType.IsRecord or LType.IsDynamicArrayOfRecord then TMARSMessageBodyWriter.WriteWith<TRecordWriter>(AValue, AMediaType, AOutputStream, AActivation) else if LType.IsObjectOfType<TJSONValue> then TMARSMessageBodyWriter.WriteWith<TJSONValueWriter>(AValue, AMediaType, AOutputStream, AActivation); AActivation.Response.ContentEncoding := 'UTF-8'; end; TMARSMessageBodyWriter.WriteWith<> is a new utility function I just introduced in the "develop" branch (MARS.Core.MessageBodyWriter unit, https://github.com/andrea-magni/MARS/commit/e818d7e261e7ef2b9a1c2c714adae459c5585c56#diff-97e07c61cdc46902bf53d808b8117104R157 ). You can simply instantiate the corresponding MessageBodyWriter class as we did before. Sincerely,
  8. Uwe Raabe

    MMX for Delphi 10.3 Rio

    @ULIK Oops! Please give version 14.0.4 a try.
  9. Allen@Grijjy

    Objective-c Completion handler to Delphi

    Is that completion handler actually a objective-c block? If so, you need to implement it as a block. We discuss how to do this more easily from Delphi in an article we wrote on using Apple's Grand Central Dispatcher that might help, https://blog.grijjy.com/2018/05/20/using-the-apples-grand-central-dispatch-and-androids-scheduledthreadpoolexecutor-for-delphi-timers/
×