|
Java™ by example!
|
|
|
How do I get all persistent JDO instances of a class?
The JDO class to use here is the Extent. An extent represents all of the instances of a class and its subclasses. Create an extent by calling the method getExtent on a PersistenceManager object, passing it the class and a boolean indicating as to whether instances of subclasses should be included. The following example prints out the objects made persistent in the QA "How do I get started with JDO". UsingExtent.java:
outputs:
Further Information
Author of answer: Joris Van den Bogaert
Comments to this answer are only viewable by members. Login or become a member!
|
|
|
|
|