summaryrefslogtreecommitdiff
path: root/org.genivi.commonapi.core/src/org/genivi/commonapi/core/generator/FrancaGeneratorExtensions.xtend
diff options
context:
space:
mode:
Diffstat (limited to 'org.genivi.commonapi.core/src/org/genivi/commonapi/core/generator/FrancaGeneratorExtensions.xtend')
-rw-r--r--org.genivi.commonapi.core/src/org/genivi/commonapi/core/generator/FrancaGeneratorExtensions.xtend25
1 files changed, 8 insertions, 17 deletions
diff --git a/org.genivi.commonapi.core/src/org/genivi/commonapi/core/generator/FrancaGeneratorExtensions.xtend b/org.genivi.commonapi.core/src/org/genivi/commonapi/core/generator/FrancaGeneratorExtensions.xtend
index ebee483..9dbf72d 100644
--- a/org.genivi.commonapi.core/src/org/genivi/commonapi/core/generator/FrancaGeneratorExtensions.xtend
+++ b/org.genivi.commonapi.core/src/org/genivi/commonapi/core/generator/FrancaGeneratorExtensions.xtend
@@ -999,31 +999,22 @@ class FrancaGeneratorExtensions {
def getFrancaVersion() {
val bundle = FrameworkUtil::getBundle(FrancaGeneratorExtensions)
- if (bundle != null) {
- val bundleContext = bundle.getBundleContext();
- for (b : bundleContext.bundles) {
- if (b.symbolicName.equals("org.franca.core")) {
- return b.version.toString
- }
+ val bundleContext = bundle.getBundleContext();
+ for (b : bundleContext.bundles) {
+ if (b.symbolicName.equals("org.franca.core")) {
+ return b.version.toString
}
}
- var version = FPreferences::instance.getPreference(null, PreferenceConstants::FRANCA_VERSION, "Error");
- if (version==null)
- return "0.8.10"
- return version
}
def static getCoreVersion() {
val bundle = FrameworkUtil::getBundle(FrancaGeneratorExtensions)
- if (bundle != null) {
- val bundleContext = bundle.getBundleContext();
- for (b : bundleContext.bundles) {
- if (b.symbolicName.equals("org.genivi.commonapi.core")) {
- return b.version.toString
- }
+ val bundleContext = bundle.getBundleContext();
+ for (b : bundleContext.bundles) {
+ if (b.symbolicName.equals("org.genivi.commonapi.core")) {
+ return b.version.toString
}
}
- return "2.1.5"
}
def generateCommonApiLicenseHeader(FModelElement model, IResource modelid) '''