use of de.djuelg.neuronizer.storage.converter.TodoListDAOConverter in project Neuronizer by djuelg.
the class TodoListRepositoryImpl method getTodoListById.
@Override
public Optional<TodoList> getTodoListById(String uuid) {
Realm realm = Realm.getInstance(configuration);
Optional<TodoListDAO> todoListDAO = Optional.fromNullable(realm.where(TodoListDAO.class).equalTo("uuid", uuid).findFirst());
Optional<TodoList> todoList = todoListDAO.transform(new TodoListDAOConverter());
realm.close();
return todoList;
}
Aggregations