コード例 #1
0
 @Override
 protected void cleanup(ModuleRevision revision) {
   Generation generation = (Generation) revision.getRevisionInfo();
   generation.delete();
   if (revision.equals(getCurrentRevision())) {
     // uninstall case
     generation.getBundleInfo().delete();
   }
 }
コード例 #2
0
 List<Generation> getGenerations() {
   List<Generation> result = new ArrayList<Generation>();
   ModuleRevision current = getModule().getCurrentRevision();
   result.add((Generation) current.getRevisionInfo());
   ModuleWiring wiring = current.getWiring();
   if (wiring != null) {
     List<ModuleWire> hostWires = wiring.getProvidedModuleWires(HostNamespace.HOST_NAMESPACE);
     if (hostWires != null) {
       for (ModuleWire hostWire : hostWires) {
         result.add((Generation) hostWire.getRequirer().getRevisionInfo());
       }
     }
   }
   return result;
 }