Does anyone know how I can do the equivalent of this in hibernate:
session.getIdentifier(instance);
with JPA?
EntityManager has a contains method but that's pretty much it!
I'm writing some code that acts as a transformer between entities and data stored in a session (so rather than a serialized object being stored just the class name and the id is stored).