#1 2022-11-29 11:29:57

itSDS
Member
From: Germany
Registered: 2014-04-24
Posts: 516

Removing jpoNullDontReleaseObjectInstance from Interfacefactory

Hi AB to Remove jpoNullDontReleaseObjectInstance from my Interfacefactory i had to patch mormot.core.interfaces.pas
Is there another way ?

My Problem is that the autocreateted Objects in my Client also contain "empty" SubObjects although the received JSON contains "subobject:null"


Rad Studio 12.1 Santorini

Offline

#2 2022-11-29 13:55:39

ab
Administrator
From: France
Registered: 2010-06-21
Posts: 14,655
Website

Re: Removing jpoNullDontReleaseObjectInstance from Interfacefactory

What do you mean by "remove jpoNullDontReleaseObjectInstance" ?

You don't need to patch the source code, you can just change the TInterfaceFactory.JsonParserOptions property.

TInterfaceFactory.Get(ISomeSOAService).JsonParserOptions := [....];

Offline

#3 2022-11-29 16:15:17

itSDS
Member
From: Germany
Registered: 2014-04-24
Posts: 516

Re: Removing jpoNullDontReleaseObjectInstance from Interfacefactory

Thank you that's i was looking for.


Rad Studio 12.1 Santorini

Offline

Board footer

Powered by FluxBB