Last active
January 29, 2017 11:12
-
-
Save vpiotr/83b36377aaf50ec4f7b0 to your computer and use it in GitHub Desktop.
Demonstrates how to use xnode as cache.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include "xnode_property_list.h" | |
#include "xnode.h" | |
xnode_named_list cache; | |
// already existing entries will automatically destroyed and replaced | |
cache.put("MAMA", xnode.value_of("mama")); | |
cache.put("PAPA", xnode().hold(new Person("PAPA"))); | |
cache.put("TRUMP", xnode().hold(new USPresident("TRUMP"))); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment