The Vera Community forums have moved!

Advanced => Programming => General => Topic started by: Ap15e on January 19, 2012, 09:55:11 am

Title: <staticJson2>
Post by: Ap15e on January 19, 2012, 09:55:11 am
Any chance to see  <staticJson2> implemented for UI5?
Title: Re: <staticJson2>
Post by: mcvflorin on January 19, 2012, 10:13:56 am
What would it be used for?
Title: Re: <staticJson2>
Post by: Ap15e on January 19, 2012, 02:58:47 pm
IMHO it is impossible to create a single static json file for DAD that works with UI5 and with earlier UI versions (just try to back-port the DAD V1.1 (available soon) static json file for UI5 to UI4 ...).
 
The idea behind a <staticJson2> variable is to be able to specify different static json files for UI5 and for earlier UI (<eventList2> ...).
 
If there is a <staticJson2> value in the device definition file and we are running on UI5 (or on a later version ...), LuaUPnP should use the <staticJson2> value to create the device, otherwise it should use the <staticJson> value.
 
Benefits:
- No need for the user to decide which version of the static json file to use.
- Upgrading/Downgrading the UI wouldn't impact the plugin, the static json file would automatically be 'switched' to the right version.