I have a loaded Doctrine entity in my PHP application.
How do I check if Doctrine's array collection is already populated with data without triggering the database request?
I need this in my entity serialization logic.
I'm not sure that proposed solution of using isEmpty()
is a good one, because I don't know whether it triggers database call or not. Does it?