<%@page import="javax.jdo.*,java.util.Iterator,models.*,models.pc.*" %> <%@page isThreadSafe="false" %> <%-- more efficient and safe in a website which is not too loaded --%> <%@page errorPage="/error.jsp"%> <%! static { WebAppMgr.enhanceAll(); } %> Models List <% PersistenceManager pm = WebAppMgr.getPersistenceManager(application); try {%>

The Models List

Add  View
    <% // Display the list of guests: Extent extent = pm.getExtent(Model.class, false); Iterator itr = extent.iterator(); while (itr.hasNext()) { %>
  1. <%= itr.next() %>
  2. <% } extent.close(itr); %>

<% } finally { // Close the PersistenceManager: if (pm.currentTransaction().isActive()) pm.currentTransaction().rollback(); pm.close(); } %> Powered by ObjectDB Java/JDO Database