1 11 package org.eclipse.osgi.internal.resolver; 12 13 import java.util.Dictionary ; 14 15 import org.eclipse.osgi.service.resolver.*; 16 import org.osgi.framework.BundleException; 17 import org.osgi.framework.Version; 18 19 public class ReadOnlyState implements State { 20 private State target; 21 22 public ReadOnlyState(State target) { 23 this.target = target; 24 } 25 26 public boolean addBundle(BundleDescription description) { 27 throw new UnsupportedOperationException (); 28 } 29 30 public StateDelta compare(State state) throws BundleException { 31 return target.compare(state); 32 } 33 34 public BundleDescription getBundle(long id) { 35 return target.getBundle(id); 36 } 37 38 public BundleDescription getBundle(String symbolicName, Version version) { 39 return target.getBundle(symbolicName, version); 40 } 41 42 public BundleDescription getBundleByLocation(String location) { 43 return target.getBundleByLocation(location); 44 } 45 46 public BundleDescription[] getBundles() { 47 return target.getBundles(); 48 } 49 50 public BundleDescription[] getBundles(String symbolicName) { 51 return target.getBundles(symbolicName); 52 } 53 54 public StateDelta getChanges() { 55 return target.getChanges(); 56 } 57 58 public ExportPackageDescription[] getExportedPackages() { 59 return target.getExportedPackages(); 60 } 61 62 public StateObjectFactory getFactory() { 63 return target.getFactory(); 64 } 65 66 public BundleDescription[] getResolvedBundles() { 67 return target.getResolvedBundles(); 68 } 69 70 public long getTimeStamp() { 71 return target.getTimeStamp(); 72 } 73 74 public boolean isEmpty() { 75 return target.isEmpty(); 76 } 77 78 public boolean isResolved() { 79 return target.isResolved(); 80 } 81 82 public boolean removeBundle(BundleDescription bundle) { 83 throw new UnsupportedOperationException (); 84 } 85 86 public BundleDescription removeBundle(long bundleId) { 87 throw new UnsupportedOperationException (); 88 } 89 90 public StateDelta resolve() { 91 throw new UnsupportedOperationException (); 92 } 93 94 public StateDelta resolve(boolean incremental) { 95 throw new UnsupportedOperationException (); 96 } 97 98 public StateDelta resolve(BundleDescription[] discard) { 99 throw new UnsupportedOperationException (); 100 } 101 102 public void setOverrides(Object value) { 103 throw new UnsupportedOperationException (); 104 } 105 106 public boolean updateBundle(BundleDescription newDescription) { 107 throw new UnsupportedOperationException (); 108 } 109 110 public void resolveConstraint(VersionConstraint constraint, BaseDescription supplier) { 111 throw new UnsupportedOperationException (); 112 } 113 114 public void resolveBundle(BundleDescription bundle, boolean status, BundleDescription[] host, ExportPackageDescription[] selectedExports, BundleDescription[] resolvedRequires, ExportPackageDescription[] resolveImports) { 115 throw new UnsupportedOperationException (); 116 } 117 118 public void removeBundleComplete(BundleDescription bundle) { 119 throw new UnsupportedOperationException (); 120 } 121 122 public Resolver getResolver() { 123 return null; 124 } 125 126 public void setResolver(Resolver value) { 127 throw new UnsupportedOperationException (); 128 } 129 130 public boolean setPlatformProperties(Dictionary platformProperties) { 131 throw new UnsupportedOperationException (); 132 } 133 134 public boolean setPlatformProperties(Dictionary platformProperties[]) { 135 throw new UnsupportedOperationException (); 136 } 137 138 public Dictionary [] getPlatformProperties() { 139 return target.getPlatformProperties(); 140 } 141 142 public ExportPackageDescription linkDynamicImport(BundleDescription importingBundle, String requestedPackage) { 143 throw new UnsupportedOperationException (); 144 } 145 146 public void setTimeStamp(long timeStamp) { 147 throw new UnsupportedOperationException (); 148 } 149 150 public ExportPackageDescription[] getSystemPackages() { 151 return target.getSystemPackages(); 152 } 153 154 public void addResolverError(BundleDescription bundle, int type, String data, VersionConstraint unsatisfied) { 155 throw new UnsupportedOperationException (); 156 } 157 158 public ResolverError[] getResolverErrors(BundleDescription bundle) { 159 return target.getResolverErrors(bundle); 160 } 161 162 public void removeResolverErrors(BundleDescription bundle) { 163 throw new UnsupportedOperationException (); 164 } 165 166 public StateHelper getStateHelper() { 167 return StateHelperImpl.getInstance(); 168 } 169 170 public long getHighestBundleId() { 171 return target.getHighestBundleId(); 172 } 173 } 174 | Popular Tags |