Skip to content
This repository has been archived by the owner on Jan 5, 2021. It is now read-only.

Commit

Permalink
#899 introduced xpand generator plugin
Browse files Browse the repository at this point in the history
  • Loading branch information
andreasmuelder committed Aug 12, 2016
1 parent 5b58e6c commit a17f676
Show file tree
Hide file tree
Showing 13 changed files with 106 additions and 40 deletions.
31 changes: 0 additions & 31 deletions plugins/org.yakindu.sct.generator.core/plugin.xml
Original file line number Diff line number Diff line change
Expand Up @@ -11,11 +11,6 @@
defaultProvider="org.yakindu.sct.generator.core.features.impl.CoreLibraryDefaultFeatureValueProvider"
uri="platform:/plugin/org.yakindu.sct.generator.core/library/CoreFeatureTypeLibrary.xmi">
</FeatureLibrary>
<FeatureLibrary
library_id="org.yakindu.generator.core.features.xpand"
defaultProvider="org.yakindu.sct.generator.core.features.impl.XpandLibraryDefaultFeatureValueProvider"
uri="platform:/plugin/org.yakindu.sct.generator.core/library/XpandFeatureTypeLibrary.xmi">
</FeatureLibrary>
<FeatureLibrary
library_id="org.yakindu.generator.core.features.generic"
defaultProvider="org.yakindu.sct.generator.core.features.impl.GenericJavaLibraryDefaultValueProvider"
Expand All @@ -27,32 +22,6 @@
uri="platform:/plugin/org.yakindu.sct.generator.core/library/SCTBaseFeatureLibrary.xmi">
</FeatureLibrary>
</extension>
<extension
point="org.yakindu.sct.generator.core.generator">
<SCTGenerator
class="org.yakindu.sct.generator.core.impl.GenericXPandCodeGenerator"
contentType="statechart"
description="Generate Code using Xpand Templates"
elementRefType="org.yakindu.sct.model.sgraph.Statechart"
icon="icons/sct.png"
id="yakindu::xpand"
name="Custom Xpand-based Generator">
<FeatureLibrary
library_id="org.yakindu.generator.core.features">
</FeatureLibrary>
<FeatureLibrary
library_id="org.yakindu.generator.core.features.xpand">
</FeatureLibrary>
</SCTGenerator>
</extension>
<extension
point="org.yakindu.sct.generator.core.extensions">
<ExtensionGeneratorMapping
fileExtension="sct"
generatorId="yakindu::xpand">
</ExtensionGeneratorMapping>
</extension>

<extension
point="org.yakindu.sct.generator.core.generator">
<SCTGenerator
Expand Down
7 changes: 7 additions & 0 deletions plugins/org.yakindu.sct.generator.xpand/.classpath
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
<?xml version="1.0" encoding="UTF-8"?>
<classpath>
<classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.7"/>
<classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
<classpathentry kind="src" path="src"/>
<classpathentry kind="output" path="bin"/>
</classpath>
1 change: 1 addition & 0 deletions plugins/org.yakindu.sct.generator.xpand/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
/bin/
28 changes: 28 additions & 0 deletions plugins/org.yakindu.sct.generator.xpand/.project
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
<?xml version="1.0" encoding="UTF-8"?>
<projectDescription>
<name>org.yakindu.sct.generator.xpand</name>
<comment></comment>
<projects>
</projects>
<buildSpec>
<buildCommand>
<name>org.eclipse.jdt.core.javabuilder</name>
<arguments>
</arguments>
</buildCommand>
<buildCommand>
<name>org.eclipse.pde.ManifestBuilder</name>
<arguments>
</arguments>
</buildCommand>
<buildCommand>
<name>org.eclipse.pde.SchemaBuilder</name>
<arguments>
</arguments>
</buildCommand>
</buildSpec>
<natures>
<nature>org.eclipse.pde.PluginNature</nature>
<nature>org.eclipse.jdt.core.javanature</nature>
</natures>
</projectDescription>
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
eclipse.preferences.version=1
org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled
org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.7
org.eclipse.jdt.core.compiler.compliance=1.7
org.eclipse.jdt.core.compiler.problem.assertIdentifier=error
org.eclipse.jdt.core.compiler.problem.enumIdentifier=error
org.eclipse.jdt.core.compiler.source=1.7
10 changes: 10 additions & 0 deletions plugins/org.yakindu.sct.generator.xpand/META-INF/MANIFEST.MF
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
Manifest-Version: 1.0
Bundle-ManifestVersion: 2
Bundle-Name: YAKINDU Xpand Generator
Bundle-SymbolicName: org.yakindu.sct.generator.xpand;singleton:=true
Bundle-Version: 2.7.1.qualifier
Bundle-Vendor: statecharts.org
Bundle-RequiredExecutionEnvironment: JavaSE-1.7
Require-Bundle: org.yakindu.sct.generator.core,
org.yakindu.sct.generator.genmodel,
org.yakindu.sct.commons
6 changes: 6 additions & 0 deletions plugins/org.yakindu.sct.generator.xpand/build.properties
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
source.. = src/
output.. = bin/
bin.includes = META-INF/,\
.,\
plugin.xml,\
icons/
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
37 changes: 37 additions & 0 deletions plugins/org.yakindu.sct.generator.xpand/plugin.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,37 @@
<?xml version="1.0" encoding="UTF-8"?>
<?eclipse version="3.4"?>
<plugin>
<extension
point="org.yakindu.sct.generator.core.featuretypes">
<FeatureLibrary
library_id="org.yakindu.generator.core.features.xpand"
defaultProvider="org.yakindu.sct.generator.core.features.impl.XpandLibraryDefaultFeatureValueProvider"
uri="platform:/plugin/org.yakindu.sct.generator.core/library/XpandFeatureTypeLibrary.xmi">
</FeatureLibrary>
</extension>
<extension
point="org.yakindu.sct.generator.core.generator">
<SCTGenerator
class="org.yakindu.sct.generator.xpand.GenericXPandCodeGenerator"
contentType="statechart"
description="Generate Code using Xpand Templates"
elementRefType="org.yakindu.sct.model.sgraph.Statechart"
icon="icons/sct.png"
id="yakindu::xpand"
name="Custom Xpand-based Generator">
<FeatureLibrary
library_id="org.yakindu.generator.core.features">
</FeatureLibrary>
<FeatureLibrary
library_id="org.yakindu.generator.core.features.xpand">
</FeatureLibrary>
</SCTGenerator>
</extension>
<extension
point="org.yakindu.sct.generator.core.extensions">
<ExtensionGeneratorMapping
fileExtension="sct"
generatorId="yakindu::xpand">
</ExtensionGeneratorMapping>
</extension>
</plugin>
Original file line number Diff line number Diff line change
Expand Up @@ -8,11 +8,11 @@
* committers of YAKINDU - initial API and implementation
*
*/
package org.yakindu.sct.generator.core.impl;
package org.yakindu.sct.generator.xpand;

import static org.yakindu.sct.generator.core.features.IXpandFeatureConstants.TEMPLATE_FEATURE;
import static org.yakindu.sct.generator.core.features.IXpandFeatureConstants.TEMPLATE_FEATURE_TEMPLATE_PATH;
import static org.yakindu.sct.generator.core.features.IXpandFeatureConstants.TEMPLATE_FEATURE_TEMPLATE_PROJECT;
import static org.yakindu.sct.generator.xpand.features.IXpandFeatureConstants.TEMPLATE_FEATURE;
import static org.yakindu.sct.generator.xpand.features.IXpandFeatureConstants.TEMPLATE_FEATURE_TEMPLATE_PATH;
import static org.yakindu.sct.generator.xpand.features.IXpandFeatureConstants.TEMPLATE_FEATURE_TEMPLATE_PROJECT;

import org.eclipse.core.resources.IProject;
import org.eclipse.core.resources.ResourcesPlugin;
Expand All @@ -22,6 +22,7 @@
import org.eclipse.emf.mwe.core.resources.ResourceLoaderFactory;
import org.eclipse.emf.mwe.core.resources.ResourceLoaderImpl;
import org.yakindu.sct.commons.WorkspaceClassLoaderFactory;
import org.yakindu.sct.generator.core.impl.AbstractXpandBasedCodeGenerator;
import org.yakindu.sct.model.sgen.FeatureConfiguration;
import org.yakindu.sct.model.sgen.FeatureParameterValue;
import org.yakindu.sct.model.sgen.GeneratorEntry;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
* Contributors:
* committers of YAKINDU - initial API and implementation
*/
package org.yakindu.sct.generator.core.features;
package org.yakindu.sct.generator.xpand.features;

/**
*
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,11 +8,11 @@
* committers of YAKINDU - initial API and implementation
*
*/
package org.yakindu.sct.generator.core.features.impl;
package org.yakindu.sct.generator.xpand.features;

import static org.yakindu.sct.generator.core.features.IXpandFeatureConstants.LIBRARY_NAME;
import static org.yakindu.sct.generator.core.features.IXpandFeatureConstants.TEMPLATE_FEATURE_TEMPLATE_PATH;
import static org.yakindu.sct.generator.core.features.IXpandFeatureConstants.TEMPLATE_FEATURE_TEMPLATE_PROJECT;
import static org.yakindu.sct.generator.xpand.features.IXpandFeatureConstants.LIBRARY_NAME;
import static org.yakindu.sct.generator.xpand.features.IXpandFeatureConstants.TEMPLATE_FEATURE_TEMPLATE_PATH;
import static org.yakindu.sct.generator.xpand.features.IXpandFeatureConstants.TEMPLATE_FEATURE_TEMPLATE_PROJECT;

import org.eclipse.core.runtime.IStatus;
import org.eclipse.core.runtime.Status;
Expand Down

0 comments on commit a17f676

Please sign in to comment.