#include #include "storage/model/properties/properties.hpp" #include "storage/model/properties/property.hpp" #include "storage/model/properties/traversers/jsonwriter.hpp" using std::endl; using std::cout; int main(void) { Properties props; props.set("awesome", true); props.set("lame", false); props.set("age", 32); // integral Int32 a = 12; Int32 b = 24; Int32 c = b; Property& d = b; cout << "a = " << a << "; b = " << b << endl; cout << (a > b) << (a < b) << (a == b) << (a != b) << endl; cout << "b == d" << " -> " << (b == d) << endl; Float x = 3.14; Float y = 6.28; Float z = x * 3.28 / y + a * b + 3; cout << x << endl; cout << z << endl; props.set("pi", z); cout << props.at("awesome") << endl; cout << props.at("lame") << endl; cout << props.at("age") << endl; cout << props.at("pi") << endl; cout << props.at("lol") << endl; StringBuffer buffer; JsonWriter writer(buffer); props.accept(writer); cout << buffer.str() << endl; return 0; }