1 11 12 package org.eclipse.osgi.baseadaptor.loader; 13 14 import java.io.IOException ; 15 import java.security.ProtectionDomain ; 16 import org.eclipse.osgi.baseadaptor.BaseData; 17 import org.osgi.framework.FrameworkEvent; 18 19 24 public class FragmentClasspath { 25 private BaseData bundledata; 26 private ClasspathEntry[] entries; 27 private ProtectionDomain domain; 28 29 public FragmentClasspath(BaseData bundledata, ClasspathEntry[] entries, ProtectionDomain domain) { 30 this.bundledata = bundledata; 31 this.entries = entries; 32 this.domain = domain; 33 } 34 35 39 public BaseData getBundleData() { 40 return bundledata; 41 } 42 43 47 public ProtectionDomain getDomain() { 48 return domain; 49 } 50 51 55 public ClasspathEntry[] getEntries() { 56 return entries; 57 } 58 59 63 public void close() { 64 for (int i = 0; i < entries.length; i++) { 65 try { 66 entries[i].getBundleFile().close(); 67 } catch (IOException e) { 68 bundledata.getAdaptor().getEventPublisher().publishFrameworkEvent(FrameworkEvent.ERROR, bundledata.getBundle(), e); 69 } 70 } 71 } 72 73 } 74 | Popular Tags |