Fix JSON Array documentation

getValue doesn't exist, use getElement instead
This commit is contained in:
Pascal Bach 2016-05-12 16:09:36 +02:00
parent e2a443ae10
commit 10475027a6

View File

@ -47,7 +47,7 @@ class JSON_API Array
/// Var result = parser.parse(json);
/// Array::Ptr arr = result.extract<Array::Ptr>();
/// Object::Ptr object = arr->getObject(0); // object == {\"test\" : 0}
/// int i = object->getValue<int>("test"); // i == 0;
/// int i = object->getElement<int>("test"); // i == 0;
/// Object::Ptr subObject = *arr->getObject(1); // subObject == {\"test\" : 0}
/// Array subArr::Ptr = subObject->getArray("test1"); // subArr == [1, 2, 3]
/// i = result = subArr->get(0); // i == 1;