public static Item getItem(final int typeID) {
   Item item = StaticData.get().getItems().get(typeID);
   if (item != null) {
     return item;
   } else {
     return new Item(typeID);
   }
 }
 public static String flag(final int flag, final MyAsset parentAsset) {
   ItemFlag itemFlag = StaticData.get().getItemFlags().get(flag);
   if (itemFlag != null) {
     if (parentAsset != null && !parentAsset.getFlag().isEmpty()) {
       return parentAsset.getFlag() + " > " + itemFlag.getFlagName();
     } else {
       return itemFlag.getFlagName();
     }
   }
   return "!" + flag;
 }
 StockpileItem showEdit(final StockpileItem addStockpileItem) {
   updateData();
   this.stockpileItem = addStockpileItem;
   this.getDialog().setTitle(TabsStockpile.get().editStockpileItem());
   Item item = StaticData.get().getItems().get(addStockpileItem.getTypeID());
   jItems.setSelectedItem(item);
   jCopy.setSelected(addStockpileItem.isBPC());
   jCountMinimum.setText(String.valueOf(addStockpileItem.getCountMinimum()));
   show();
   return stockpileItem;
 }
 public static void addLocation(final Station station) {
   MyLocation system = getLocation(station.getSolarSystemID());
   MyLocation location =
       new MyLocation(
           station.getStationID(),
           station.getStationName(),
           system.getSystemID(),
           system.getSystem(),
           system.getRegionID(),
           system.getRegion(),
           system.getSecurity());
   StaticData.get().getLocations().put(location.getLocationID(), location);
 }
 public static float getVolume(final int typeID, final boolean packaged) {
   Item item = StaticData.get().getItems().get(typeID);
   if (item != null) {
     if (packagedVolume.isEmpty()) {
       buildVolume();
     }
     if (packaged && packagedVolume.containsKey(item.getGroup())) {
       return packagedVolume.get(item.getGroup());
     } else {
       return item.getVolume();
     }
   }
   return 0;
 }
 private void updateData() {
   stockpile = null;
   stockpileItem = null;
   List<Item> itemsList = new ArrayList<Item>(StaticData.get().getItems().values());
   Collections.sort(itemsList);
   try {
     items.getReadWriteLock().writeLock().lock();
     items.clear();
     items.addAll(itemsList);
   } finally {
     items.getReadWriteLock().writeLock().unlock();
   }
   jItems.setSelectedIndex(0);
   jCountMinimum.setText("");
   jItems.setEnabled(true);
 }
 public static MyLocation getLocation(long locationID, final MyAsset parentAsset) {
   // Offices
   if (locationID >= 66000000) {
     if (locationID < 66014933) {
       locationID = locationID - 6000001;
     } else {
       locationID = locationID - 6000000;
     }
   }
   MyLocation location = StaticData.get().getLocations().get(locationID);
   if (location != null) {
     return location;
   }
   if (parentAsset != null) {
     location = parentAsset.getLocation();
     if (location != null) {
       return location;
     }
   }
   return new MyLocation(locationID);
 }