public String toString() { StringBuffer buf = new StringBuffer(20); toString(buf); return buf.toString(); }
public FeatureEntry(String id, String version, boolean isPlugin) { this.id = id; this.versionOrRange = Version.parseVersion(version).toString(); this.isPlugin = isPlugin; }
public FeatureEntry(String id, String version, boolean isPlugin) { this.id = id; this.versionOrRange = Version.parseVersion(version).toString(); this.isPlugin = isPlugin; }
public static org.eclipse.tycho.ArtifactKey toTychoArtifact(IInstallableUnit unit) { // TODO 428889 unit test & add more cases if (Boolean.valueOf(unit.getProperty(InstallableUnitDescription.PROP_TYPE_GROUP))) { // TODO 428889 check suffix String id = unit.getId(); return new DefaultArtifactKey(ArtifactType.TYPE_ECLIPSE_FEATURE, id.substring(0, id.length() - ".feature.group".length()), unit.getVersion().toString()); } throw new IllegalArgumentException(unit.toString()); }
public String getText(Object element) { if (element instanceof RemedyIUDetail) { RemedyIUDetail iu = (RemedyIUDetail) element; if (iu.getBeingInstalledVersion() != null) return iu.getBeingInstalledVersion().toString(); } return ""; //$NON-NLS-1$ } });
public IUPropertiesHandler(AbstractHandler parentHandler, Attributes attributes, Map<String, Map<String, String>> iusPropertiesMap) { super(parentHandler, IU_PROPERTIES_ELEMENT); this.iusPropertiesMap = iusPropertiesMap; String values[] = parseRequiredAttributes(attributes, required); String id = values[0]; Version version = checkVersion(IU_PROPERTIES_ELEMENT, VERSION_ATTRIBUTE, values[1]); iuIdentity = id + "_" + version.toString(); //$NON-NLS-1$ }
public String getText(Object element) { IInstallableUnit iu = ProvUI.getAdapter(element, IInstallableUnit.class); if (element instanceof IIUElement) { if (((IIUElement) element).shouldShowVersion()) return iu.getVersion().toString(); return ""; //$NON-NLS-1$ } return iu.getVersion().toString(); } });
public synchronized Touchpoint getTouchpoint(ITouchpointType type) { if (type == null) throw new IllegalArgumentException(Messages.TouchpointManager_Null_Touchpoint_Type_Argument); return getTouchpoint(type.getId(), type.getVersion().toString()); }
public Map<String, String> getIUProperties(IInstallableUnit iu) { if (iusPropertiesHandler == null) return null; Map<String, Map<String, String>> iusPropertiesMap = iusPropertiesHandler.getIUsPropertiesMap(); if (iusPropertiesMap == null) return null; String iuIdentity = iu.getId() + "_" + iu.getVersion().toString(); //$NON-NLS-1$ return iusPropertiesMap.get(iuIdentity); } }
public Map<String, String> getIUProperties(IInstallableUnit iu) { if (iusPropertiesHandler == null) return null; Map<String, Map<String, String>> iusPropertiesMap = iusPropertiesHandler.getIUsPropertiesMap(); if (iusPropertiesMap == null) return null; String iuIdentity = iu.getId() + "_" + iu.getVersion().toString(); //$NON-NLS-1$ return iusPropertiesMap.get(iuIdentity); } }
public synchronized Touchpoint getTouchpoint(ITouchpointType type) { if (type == null) throw new IllegalArgumentException(Messages.TouchpointManager_Null_Touchpoint_Type_Argument); return getTouchpoint(type.getId(), type.getVersion().toString()); }
public void removeBundle(File bundleFile, String bundleId, Version bundleVersion) throws MalformedURLException, IOException { if (sourceBundles == null) load(); BundleInfo sourceInfo = new BundleInfo(); if (bundleFile != null) sourceInfo.setLocation(bundleFile.toURI()); sourceInfo.setSymbolicName(bundleId); sourceInfo.setVersion(bundleVersion.toString()); sourceBundles.remove(sourceInfo); }
private void addProductFileBundles(ConfigData data) { List<IVersionedId> bundles = product.getBundles(true); Set<BundleInfo> set = new HashSet<BundleInfo>(); set.addAll(Arrays.asList(data.getBundles())); for (IVersionedId vid : bundles) { BundleInfo bundleInfo = new BundleInfo(); bundleInfo.setSymbolicName(vid.getId()); bundleInfo.setVersion(vid.getVersion().toString()); if (!set.contains(bundleInfo)) data.addBundle(bundleInfo); } }
private void addProductFileBundles(ConfigData data) { List<IVersionedId> bundles = product.getBundles(true); Set<BundleInfo> set = new HashSet<BundleInfo>(); set.addAll(Arrays.asList(data.getBundles())); for (IVersionedId vid : bundles) { BundleInfo bundleInfo = new BundleInfo(); bundleInfo.setSymbolicName(vid.getId()); bundleInfo.setVersion(vid.getVersion().toString()); if (!set.contains(bundleInfo)) data.addBundle(bundleInfo); } }
private void addProductFileBundles(ConfigData data) { List<IVersionedId> bundles = product.getBundles(true); Set<BundleInfo> set = new HashSet<>(); set.addAll(Arrays.asList(data.getBundles())); for (IVersionedId vid : bundles) { BundleInfo bundleInfo = new BundleInfo(); bundleInfo.setSymbolicName(vid.getId()); bundleInfo.setVersion(vid.getVersion().toString()); if (!set.contains(bundleInfo)) data.addBundle(bundleInfo); } }
private void addExternalMavenArtifact(DefaultP2ResolutionResult result, IArtifactFacade mavenArtifact, IInstallableUnit iu) { String id = iu.getId(); String version = iu.getVersion().toString(); String mavenClassifier = iu.getProperty(RepositoryLayoutHelper.PROP_CLASSIFIER); File location = mavenArtifact.getLocation(); addMavenArtifact(result, iu, id, version, mavenClassifier, location); }
/** * @see #flatButPackedEnabled(IArtifactDescriptor) */ private URI getLocationForPackedButFlatArtifacts(IArtifactDescriptor descriptor) { IArtifactKey key = descriptor.getArtifactKey(); return mapper.map(getLocation(), key.getClassifier(), key.getId(), key.getVersion().toString(), descriptor.getProperty(IArtifactDescriptor.FORMAT)); }
/** * @see #flatButPackedEnabled(IArtifactDescriptor) */ private URI getLocationForPackedButFlatArtifacts(IArtifactDescriptor descriptor) { IArtifactKey key = descriptor.getArtifactKey(); return mapper.map(getLocation(), key.getClassifier(), key.getId(), key.getVersion().toString(), descriptor.getProperty(IArtifactDescriptor.FORMAT)); }
public void initialize(RepositoryState state) { setName(state.Name); setType(state.Type); setVersion(state.Version.toString()); setProvider(state.Provider); setDescription(state.Description); setLocation(state.Location); setProperties(state.Properties); }
public synchronized void initialize(RepositoryState state) { setName(state.Name); setType(state.Type); setVersion(state.Version.toString()); setProvider(state.Provider); setDescription(state.Description); setLocation(state.Location); setProperties(state.Properties); this.units.addAll(state.Units); this.references = CollectionUtils.unmodifiableList(state.Repositories); }