Is there a way to delete an entity without having to fetch it from the datastore first? I am assuming I already have the key or id for the entity.
I'm thinking of something like deleteObjectById
that would be an analogue to getObjectById
on PersistenceManager
.
The closest I can think of is using Query.deletePersistentAll()
(as seen here) and specifying a query that only relies on the key, but I can't tell if that is going to fetch the entity before deleting it.
thanks
EDIT: I know how to do this using the low level API, as well as in the python API. I was wondering if there was a way to do it within the JDO layer.