| 113 | |
| 114 | template <typename T> |
| 115 | T getElement(unsigned int index) const |
| 116 | /// Retrieves an element and tries to convert it to the |
| 117 | /// template type. The convert<T> method of |
| 118 | /// Dynamic is called which can also throw |
| 119 | /// exceptions for invalid values. |
| 120 | /// Note: This will not work for an array or an object. |
| 121 | { |
| 122 | Dynamic::Var value = get(index); |
| 123 | return value.convert<T>(); |
| 124 | } |
| 125 | |
| 126 | SharedPtr<Object> getObject(unsigned int index) const; |
| 127 | /// Retrieves an object. When the element is not |
no test coverage detected