[mythtv] Conversion of Service API

Bill Meek keemllib at gmail.com
Mon Jun 28 18:47:57 UTC 2021


On 6/28/21 1:39 PM, Peter Bennett wrote:
> 
> On 6/28/21 11:10 AM, Bill Meek wrote:
>> On 6/28/21 8:39 AM, Peter Bennett wrote:
>>> I have updated the wiki page with instructions on converting services
>>>
>>> https://www.mythtv.org/wiki/Services_API_V2_Conversion
>>>
>>> If I have anything wrong or left out anything please feel free to update it or let me know.
>>>
>>> Peter
>>>
>> Thanks! Especially noted: Q_CLASSINFO("GetSavedBookmark",  "name=long").
>>
>> Solved 10 Myth service endpoints that currently return Strings or StringLists.
>>
>>
>>
>> Any opinions on the following difference?
>>
>> $ api2 --endpoint Myth/GetHostName
>> ...
>> ********** Myth/GetHostName want's XML response from Original API:
>>
>> <String>ofc0</String>
>>
>> ********** Myth/GetHostName want's XML response from V2 API:
>>
>> <String xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" serializerVersion="1.1">ofc0</String>
>>
> Hi Bill
> 
> I think that should be OK, parsers hopefully will not be affected by those new attributes in the xml. I have not looked into whether or how to
> get rid of them. I think this is a feature not a bug.
> 
> Peter

Hey Peter,

Thanks for all your examples. If I comment out lines 25/26 here:

  https://github.com/MythTV/mythtv/blob/devel/http/mythtv/libs/libmythbase/http/serialisers/mythxmlserialiser.cpp#L25

the String/StringList responses match the original. BUT, the XML for Video/GetVideos
is empty! I think I'll just leave it alone for now. But will start a section in the
Wiki where differences can be tracked. I'll note that these are know at the time and
may change prior to release.


-- 
Bill


More information about the mythtv-dev mailing list