本文整理汇总了Java中org.eclipse.core.runtime.PluginVersionIdentifier类的典型用法代码示例。如果您正苦于以下问题:Java PluginVersionIdentifier类的具体用法?Java PluginVersionIdentifier怎么用?Java PluginVersionIdentifier使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。
PluginVersionIdentifier类属于org.eclipse.core.runtime包,在下文中一共展示了PluginVersionIdentifier类的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: initializeFeatureUpdateManager
import org.eclipse.core.runtime.PluginVersionIdentifier; //导入依赖的package包/类
private void initializeFeatureUpdateManager() {
FeatureUpdateChecker gwtSdkChecker = new FeatureUpdateChecker(new UpdateComputer() {
@Override
public UpdateInfo checkSiteXMLForUpdates(Element siteXMLRootElem) {
GwtMaxSdkVersionComputer maxVersionComputer = new GwtMaxSdkVersionComputer();
String maxGwtSdkVersion = maxVersionComputer.computeMaxSdkVersion(getJavaProjects());
if (maxGwtSdkVersion == null) {
/*
* Doesn't look like the GWT SDK is being used in the workspace;
* indicate that there is no update available
*/
return new UpdateInfo(GWT_SDK_BUNDLE_FEATURE_ID);
}
return doCheckSiteXMLForUpdates(
GWT_SDK_BUNDLE_FEATURE_ID,
new PluginVersionIdentifier(maxGwtSdkVersion),
GdtPreferences.getVersionForLastAcknowledgedUpdateNotification(GWT_SDK_BUNDLE_FEATURE_ID),
siteXMLRootElem, false);
}
});
FeatureUpdateCheckersMap updateCheckersMap = new FeatureUpdateCheckersMap(UpdateSiteToken.class);
updateCheckersMap.put(UpdateSiteToken.GWT_SDK, gwtSdkChecker);
UpdateSiteURLGenerator generator = new UpdateSiteURLGenerator();
featureUpdateManager = new FeatureUpdateManager(generator, updateCheckersMap);
analyticsPingManager = new AnalyticsPingManager(generator);
}
示例2: setUpdatedFeatureVersion
import org.eclipse.core.runtime.PluginVersionIdentifier; //导入依赖的package包/类
public void setUpdatedFeatureVersion(
PluginVersionIdentifier updatedFeatureVersion) {
if (updatedFeatureVersion == null) {
this.updatedFeatureVersion = NO_VERSION;
} else {
this.updatedFeatureVersion = updatedFeatureVersion;
}
}
示例3: getVersionForLastAcknowledgedUpdateNotification
import org.eclipse.core.runtime.PluginVersionIdentifier; //导入依赖的package包/类
@SuppressWarnings("deprecation")
public static PluginVersionIdentifier getVersionForLastAcknowledgedUpdateNotification(String featureId) {
return new PluginVersionIdentifier(
getConfigurationPreferences().get(getLastAckFeatureUpdateVersionKey(featureId), "0.0.0.0"));
}
示例4: setVersionForLastAcknowlegedUpdateNotification
import org.eclipse.core.runtime.PluginVersionIdentifier; //导入依赖的package包/类
@SuppressWarnings("deprecation")
public static void setVersionForLastAcknowlegedUpdateNotification(String featureId, PluginVersionIdentifier version) {
IEclipsePreferences configurationPreferences = getConfigurationPreferences();
configurationPreferences.put(getLastAckFeatureUpdateVersionKey(featureId), version.toString());
flushPreferences(configurationPreferences);
}
示例5: getUpdatedFeatureVersion
import org.eclipse.core.runtime.PluginVersionIdentifier; //导入依赖的package包/类
/**
* If an update is available, returns the updated version that is available
* for the feature. Otherwise, returns a version of <code>0.0.0.0</code>.
*/
public PluginVersionIdentifier getUpdatedFeatureVersion() {
return updatedFeatureVersion;
}