m_lineItems = (DataAssociation) m_order.get("items");
DataAssociation items = (DataAssociation) m_order.get("items"); for (int i = 0; i < NUM_ITEMS; i++) { DataObject li = session.create("examples.LineItem"); li.set("id", new BigDecimal(i)); li.set("name", "Item " + i); li.set("price", new Float(2.99 + i)); items.add(li); m_lineItemType = li.getObjectType(); } m_order.save();  m_lineItems = (DataAssociation) m_order.get("items");
    OrderAssociation(Session session) {        BigDecimal id = new BigDecimal(1);         DataObject order = session.create("examples.Order");         order.set("id", id);         order.set("buyer", "Michael Bryzek");         order.set("shippingAddress",                     "2036 Shattuck Ave.\nBerkeley, CA 94704");         order.set("shippingDate",                     new java.sql.Date(System.currentTimeMillis()));         order.set("hasShipped", Boolean.FALSE);         order.save();                  m_order = (GenericDataObject) session.retrieve             (new OID("examples.Order", id));         DataAssociation items = (DataAssociation) m_order.get("items");         for (int i = 0; i < NUM_ITEMS; i++) {             DataObject li = session.create("examples.LineItem");             li.set("id", new BigDecimal(i));             li.set("name", "Item " + i);             li.set("price", new Float(2.99 + i));             items.add(li);             m_lineItemType = li.getObjectType();         }         m_order.save();         m_lineItems = (DataAssociation) m_order.get("items");            }