Commit e04ab0c3 authored by Lionel Seinturier's avatar Lionel Seinturier
Browse files

Rename artifact frascati-tinfi-emf to frascati-tinfi-scaadl.

parent d91955bc
......@@ -2,6 +2,7 @@ Tinfi 1.3.1
-----------
* SCA Assembly Language parser refactored to move the part specific to the
support of the OSGi implementation type in the extension/osgi module
* rename artifact frascati-tinfi-emf to frascati-tinfi-scaadl
Tinfi 1.3
......
......@@ -40,11 +40,11 @@
</dependency>
<!-- ================================================== -->
<!-- Juliac plugins: SCA EMF Parser, JDT, Spoon -->
<!-- Juliac plugins: SCA ADL Parser, JDT, Spoon -->
<!-- ================================================== -->
<dependency>
<groupId>org.ow2.frascati.tinfi</groupId>
<artifactId>frascati-tinfi-emf</artifactId>
<artifactId>frascati-tinfi-scaadl</artifactId>
<version>${project.version}</version>
</dependency>
<dependency>
......
......@@ -56,7 +56,7 @@
</executions>
<configuration>
<srcs><src>src/main/java</src></srcs>
<adlParser>org.ow2.frascati.tinfi.emf.EMFParserSourceCodeGenerator</adlParser>
<adlParser>org.ow2.frascati.tinfi.emf.EMFParserSupportImpl</adlParser>
<opts>
<opt>org.ow2.frascati.tinfi.opt.oo.FCOOCtrlSourceCodeGenerator</opt>
<opt>OO</opt>
......@@ -68,7 +68,7 @@
<adls><adl>HelloWorld</adl></adls>
<modules>
<module>org.ow2.frascati.tinfi:frascati-tinfi-oo:${project.version}</module>
<module>org.ow2.frascati.tinfi:frascati-tinfi-emf:${project.version}</module>
<module>org.ow2.frascati.tinfi:frascati-tinfi-scaadl:${project.version}</module>
<module>org.objectweb.fractal.juliac:juliac-jdt:${juliac.version}</module>
<module>org.objectweb.fractal.juliac:juliac-spoon:${juliac.version}</module>
</modules>
......
......@@ -60,7 +60,7 @@
</executions>
<configuration>
<srcs><src>src/main/java</src></srcs>
<adlParser>org.ow2.frascati.tinfi.emf.EMFParserSourceCodeGenerator</adlParser>
<adlParser>org.ow2.frascati.tinfi.emf.EMFParserSupportImpl</adlParser>
<opts>
<opt>org.ow2.frascati.tinfi.opt.oo.FCOOCtrlNoIntentSourceCodeGenerator</opt>
<opt>OO</opt>
......@@ -72,7 +72,7 @@
<adls><adl>HelloWorld</adl></adls>
<modules>
<module>org.ow2.frascati.tinfi:frascati-tinfi-oo:${project.version}</module>
<module>org.ow2.frascati.tinfi:frascati-tinfi-emf:${project.version}</module>
<module>org.ow2.frascati.tinfi:frascati-tinfi-scaadl:${project.version}</module>
<module>org.objectweb.fractal.juliac:juliac-jdt:${juliac.version}</module>
<module>org.objectweb.fractal.juliac:juliac-spoon:${juliac.version}</module>
</modules>
......
......@@ -49,7 +49,7 @@
</executions>
<configuration>
<srcs><src>src/main/java</src></srcs>
<adlParser>org.ow2.frascati.tinfi.emf.EMFParserSourceCodeGenerator</adlParser>
<adlParser>org.ow2.frascati.tinfi.emf.EMFParserSupportImpl</adlParser>
<opts>
<opt>org.ow2.frascati.tinfi.opt.oo.FCOOCtrlSourceCodeGenerator</opt>
<opt>OO</opt>
......@@ -61,7 +61,7 @@
<adls><adl>HelloWorld</adl></adls>
<modules>
<module>org.ow2.frascati.tinfi:frascati-tinfi-oo:${project.version}</module>
<module>org.ow2.frascati.tinfi:frascati-tinfi-emf:${project.version}</module>
<module>org.ow2.frascati.tinfi:frascati-tinfi-scaadl:${project.version}</module>
<module>org.objectweb.fractal.juliac:juliac-jdt:${juliac.version}</module>
<module>org.objectweb.fractal.juliac:juliac-spoon:${juliac.version}</module>
</modules>
......
......@@ -53,7 +53,7 @@
</executions>
<configuration>
<srcs><src>src/main/java</src></srcs>
<adlParser>org.ow2.frascati.tinfi.emf.EMFParserSourceCodeGenerator</adlParser>
<adlParser>org.ow2.frascati.tinfi.emf.EMFParserSupportImpl</adlParser>
<opts>
<opt>org.ow2.frascati.tinfi.opt.oo.FCOOCtrlSourceCodeGenerator</opt>
<opt>OO</opt>
......@@ -65,7 +65,7 @@
<adls><adl>HelloWorld</adl></adls>
<modules>
<module>org.ow2.frascati.tinfi:frascati-tinfi-oo:${project.version}</module>
<module>org.ow2.frascati.tinfi:frascati-tinfi-emf:${project.version}</module>
<module>org.ow2.frascati.tinfi:frascati-tinfi-scaadl:${project.version}</module>
<module>org.objectweb.fractal.juliac:juliac-jdt:${juliac.version}</module>
<module>org.objectweb.fractal.juliac:juliac-spoon:${juliac.version}</module>
</modules>
......
......@@ -13,13 +13,11 @@
<name>Tinfi Plugin SCA Assembly Language</name>
<dependencies>
<dependency>
<groupId>org.ow2.frascati.tinfi</groupId>
<artifactId>frascati-tinfi-emf</artifactId>
<artifactId>frascati-tinfi-scaadl</artifactId>
<version>${project.version}</version>
</dependency>
</dependencies>
</project>
......@@ -15,7 +15,7 @@
<dependencies>
<dependency>
<groupId>${project.groupId}</groupId>
<artifactId>frascati-tinfi-emf</artifactId>
<artifactId>frascati-tinfi-scaadl</artifactId>
<version>${project.version}</version>
</dependency>
<dependency>
......
......@@ -7,14 +7,8 @@
<version>1.3.1-SNAPSHOT</version>
</parent>
<!-- ============================================================ -->
<!-- After releasing Tinfi 1.3, change the artifact identifier to -->
<!-- frascati-tinfi-scaadl to unify naming with Juliac ADL parser -->
<!-- plugins -->
<!-- ============================================================ -->
<groupId>org.ow2.frascati.tinfi</groupId>
<artifactId>frascati-tinfi-emf</artifactId>
<artifactId>frascati-tinfi-scaadl</artifactId>
<packaging>jar</packaging>
<name>Tinfi Plugin SCA Assembly Language</name>
......
/***
* OW2 FraSCAti Tinfi
* Copyright (C) 2009-2010 INRIA, USTL
*
* This library is free software; you can redistribute it and/or
* modify it under the terms of the GNU Lesser General Public
* License as published by the Free Software Foundation; either
* version 2 of the License, or (at your option) any later version.
*
* This library is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
* Lesser General Public License for more details.
*
* You should have received a copy of the GNU Lesser General Public
* License along with this library; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
*
* Contact: frascati@ow2.org
*
* Author: Lionel Seinturier
*/
package org.ow2.frascati.tinfi.emf;
import java.io.IOException;
import java.io.InputStream;
import org.objectweb.fractal.juliac.Juliac;
import org.objectweb.fractal.juliac.conf.JuliacConfig;
import org.objectweb.fractal.juliac.plugin.ADLParserSupportItf;
/**
* This class generates the source code associated to Fractal components.
* The membrane implementation and the initializer implementation are generated.
*
* The content, the interceptors and the controllers are kept in separate
* classes and the controllers are implemented with objects.
*
* @author Lionel Seinturier <Lionel.Seinturier@univ-lille1.fr>
* @since 1.1
*/
public class EMFParserSourceCodeGenerator implements ADLParserSupportItf {
public void init( Juliac jc ) {
this.jc = jc;
}
private Juliac jc;
public boolean acceptADLDesc( String adl ) {
String adlFileName = adl.replace('.','/')+".composite";
JuliacConfig jconf = jc.getJuliacConfig();
ClassLoader loader = jconf.getClassLoader();
InputStream is = loader.getResourceAsStream(adlFileName);
boolean exist = (is != null);
return exist;
}
/**
* Parse the specified ADL descriptor and return a model of it.
*
* @param adl the fully-qualified name of the ADL descriptor
* @return the model of the specified ADL
* @since 1.3.1
*/
public <T> T parse( String adl ) throws IOException {
EMFParserSupportImpl emf = new EMFParserSupportImpl();
emf.init(jc);
// emf.<T> needed for compilation with javac
T ret = emf.<T>parse(adl);
return ret;
}
/**
* Generate the source code of a factory class for the specified ADL.
*
* @param adl the fully-qualified name of the ADL descriptor
* @param targetname the fully-qualified name of the factory class
*/
public void generate( String adl, String targetname ) throws IOException {
EMFParserSupportImpl emf = new EMFParserSupportImpl();
emf.init(jc);
emf.generate(adl,targetname);
}
}
......@@ -3,7 +3,7 @@
<parent>
<groupId>org.ow2.frascati.tinfi</groupId>
<artifactId>frascati-membranes-parent</artifactId>
<artifactId>frascati-tinfi-membranes-parent</artifactId>
<version>1.3.1-SNAPSHOT</version>
</parent>
......
......@@ -9,7 +9,7 @@
</parent>
<groupId>org.ow2.frascati.tinfi</groupId>
<artifactId>frascati-membranes-parent</artifactId>
<artifactId>frascati-tinfi-membranes-parent</artifactId>
<name>Tinfi Pre-mixed Control Membranes</name>
<packaging>pom</packaging>
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment