final int NB_PERSON = 3;
Date d = new Date();
PersistenceManager pm = pmf.getPersistenceManager();
pm.currentTransaction().begin();
for (int i = 0; i < NB_PERSON; i++) {
Address a = new Address("p_street_" + i,
"p_city_" + i,
"p_state_" + i,
"p_zipcode_" + i);
Person p = new Person("person_fn_" + i, "person_ln_" + i, a, d);
pm.makePersistent(p);
}
final int NB_WORKER = 4;
for (int i = 0; i < NB_WORKER; i++) {
Address a = new Address("w_street_" + i,
"w_city_" + i,
"w_state_" + i,
"w_zipcode_" + i);
Worker w = new Worker("worker_fn_" + i, "worker_ln_" + i, a, d,
"jobName_" + i, "company_" + i, (float) (i * 2000.0));