Hot Door CORE Forum
Creating Dictionary Prefs + PrefDataVector parameter for *members - Printable Version

+- Hot Door CORE Forum (http://hotdoorcore.com/forum)
+-- Forum: All forums (http://hotdoorcore.com/forum/forumdisplay.php?fid=1)
+--- Forum: General discussion (http://hotdoorcore.com/forum/forumdisplay.php?fid=3)
+--- Thread: Creating Dictionary Prefs + PrefDataVector parameter for *members (/showthread.php?tid=316)



Creating Dictionary Prefs + PrefDataVector parameter for *members - zero - 04-21-2022

Does anyone have an example of a hdi::core::DictionaryPref with std::vector<std::shared_ptr<hdi::core::PrefData> >?

I am having some issues building this properly. Would love some more insight into how to create these items properly, and it is related to my other post about the internetPOST requests if that helps at all.

thanks again !


RE: Creating Dictionary Prefs + PrefDataVector parameter for *members - garrett - 04-26-2022

With this constructor the intention is for you to create whatever variety of named PrefData subclass objects you need to appear at the root of a dictionary, add them to a vector, then construct the containing DictionaryPref from said vector. Each element will appear in the root of the dictionary with their respective name given when said elements were constructed.