-
Notifications
You must be signed in to change notification settings - Fork 41
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
VersionRange for root features is too tight when expanded version given
Currently the (disabled by default) requirement for a root feature uses an exact version range when the feature version is expanded (e.g. Tycho) but the purpose of a root feature is that it can be updated what such a strict range makes it impossible (if activated). This now adds a new IVersionRangeAdvice that allows to modify the result of a product included requirements version range.
- Loading branch information
Showing
5 changed files
with
94 additions
and
6 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
36 changes: 36 additions & 0 deletions
36
...quinox.p2.publisher/src/org/eclipse/equinox/p2/publisher/actions/IVersionRangeAdvice.java
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
/******************************************************************************* | ||
* Copyright (c) 2024 Christoph Läubrich and others. | ||
* | ||
* This program and the accompanying materials are made available under the terms of | ||
* the Eclipse Public License 2.0 which accompanies this distribution, and is | ||
* available at https://www.eclipse.org/legal/epl-2.0/ | ||
* | ||
* SPDX-License-Identifier: EPL-2.0 | ||
* | ||
* Contributors: | ||
* Christoph Läubrich - initial API and implementation | ||
******************************************************************************/ | ||
package org.eclipse.equinox.p2.publisher.actions; | ||
|
||
import java.util.Optional; | ||
import org.eclipse.equinox.p2.metadata.IInstallableUnit; | ||
import org.eclipse.equinox.p2.metadata.VersionRange; | ||
import org.eclipse.equinox.p2.publisher.IPublisherAdvice; | ||
import org.eclipse.equinox.spi.p2.publisher.PublisherHelper; | ||
|
||
public interface IVersionRangeAdvice extends IPublisherAdvice { | ||
|
||
public static final String NS_FEATURE = PublisherHelper.NAMESPACE_ECLIPSE_TYPE + "." //$NON-NLS-1$ | ||
+ PublisherHelper.TYPE_ECLIPSE_FEATURE; | ||
public static final String NS_IU = IInstallableUnit.NAMESPACE_IU_ID; | ||
|
||
/** | ||
* Returns the {@link VersionRange} for the given id in the given namespace. | ||
* | ||
* @param namespace the namespace in which to look for advice | ||
* @param id the id for the item in the given namespace | ||
* @return an {@link Optional} describing the {@link VersionRange} found. | ||
*/ | ||
public Optional<VersionRange> getVersionRange(String namespace, String id); | ||
|
||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters