Add support for Query/Cursor APIs