maskarade/Android-Orma

How to return cursor from (Table)_Relation object?

Closed this issue · 2 comments

I don't wanna add new dependencies for my project (such as customize adapter for use Item_Relation) in my list adapter, that working with Cursor. Can I get cursor from XXX_Relation object?

 public static Cursor getItemsList() {
        Item_Relation results = ItemRepository.getItems();
        return results.getCursor();
 }

P.S. I know about rawQuery, but builder method are more user-friendly

I'm looked generated source: I can get cursor by use selector() method.
Cursor results = ItemRepository.getItems().selector().execute();
Close issue

gfx commented

👍