PropertyGroupSchedule physicalPGSchedule = milvan.getPhysicalPGSchedule(); PhysicalPG defaultPhysicalPG = (PhysicalPG) physicalPGSchedule.getDefault(); if (defaultPhysicalPG == null) { _gp.getLoggingService().error("AmmoTransport: milvan with a null default physicalPG"); } physicalPGSchedule = PropertyGroupFactory.newPhysicalPGSchedule(defaultPhysicalPG); milvan.setPhysicalPGSchedule(physicalPGSchedule);
  protected Asset makeMilvan() {        if (MILVAN_PROTOTYPE == null) {      MILVAN_PROTOTYPE = _gp.getGPFactory().getPrototype(MILVAN_NSN);            if (MILVAN_PROTOTYPE == null) {        _gp.getLoggingService().error("AmmoTransport: Error! Unable to get prototype for" +                           " milvan NSN -" + MILVAN_NSN);        return null;      }    }        Container milvan =       (Container)_gp.getGPFactory().createInstance(MILVAN_PROTOTYPE);        // AMMO Cargo Code    NewMovabilityPG movabilityPG =       PropertyGroupFactory.newMovabilityPG(milvan.getMovabilityPG());    movabilityPG.setCargoCategoryCode(AMMO_CATEGORY_CODE);    milvan.setMovabilityPG(movabilityPG);        // Milvan Contents    NewContentsPG contentsPG =       PropertyGroupFactory.newContentsPG();    milvan.setContentsPG(contentsPG);        // Unique Item Identification    NewItemIdentificationPG itemIdentificationPG =       (NewItemIdentificationPG)milvan.getItemIdentificationPG();    String itemID = makeMilvanID();    itemIdentificationPG.setItemIdentification(itemID);    itemIdentificationPG.setNomenclature("Milvan");    itemIdentificationPG.setAlternateItemIdentification(itemID);    milvan.setItemIdentificationPG(itemIdentificationPG);    // Make unique physicalPG so weight can be modified to reflect current load    PropertyGroupSchedule physicalPGSchedule =       milvan.getPhysicalPGSchedule();    PhysicalPG defaultPhysicalPG =       (PhysicalPG) physicalPGSchedule.getDefault();    if (defaultPhysicalPG == null) {      _gp.getLoggingService().error("AmmoTransport: milvan with a null default physicalPG");    }    physicalPGSchedule =       PropertyGroupFactory.newPhysicalPGSchedule(defaultPhysicalPG);        milvan.setPhysicalPGSchedule(physicalPGSchedule);    return milvan;  }