Why does anything need to be a primary key anywhere in order to enforce some constraint?
At least from ORMs I know I can set for example any group of attributes unique. Other constraints can be implemented in some general method that is called when persisting in the actual database.
Even if no ORM, you can write a wrapper around your persisting procedure.