Commit 886f8de6 authored by dfournier's avatar dfournier
Browse files

* Add the Generate Factory

* Update Assembly Factory pom's
* Update HelloWord Example
* Update HelloWorld WebService Example
* Disable Forge and Meteo Example
parent 88b21aa2
......@@ -18,12 +18,12 @@
<dependency><!-- Artifact specified in the <mixins> tag -->
<groupId>org.scorware.tinfi.examples</groupId>
<artifactId>forge</artifactId>
<version>${project.version}</version>
<version>${tinfi.version}</version>
</dependency>
<dependency>
<groupId>org.scorware.assembly</groupId>
<artifactId>factory</artifactId>
<version>1.0-SNAPSHOT</version>
<version>${project.version}</version>
</dependency>
</dependencies>
......
......@@ -18,28 +18,28 @@
<dependency>
<groupId>org.scorware.assembly</groupId>
<artifactId>factory</artifactId>
<version>1.0-SNAPSHOT</version>
<version>${project.version}</version>
</dependency>
<dependency> <!-- Needed in all cases -->
<dependency><!-- Needed in all cases -->
<groupId>org.scorware.tinfi</groupId>
<artifactId>compiler</artifactId>
<version>${project.version}</version>
<version>${tinfi.version}</version>
</dependency>
<dependency> <!-- Needed in all cases -->
<dependency><!-- Needed in all cases -->
<groupId>org.objectweb.fractal.fractaladl.juliac</groupId>
<artifactId>runtime</artifactId>
<version>1.2</version>
<version>${juliac.version}</version>
</dependency>
<dependency> <!-- Artifact specified in the <mixins> tag -->
<dependency><!-- Artifact specified in the <mixins> tag -->
<groupId>org.scorware.tinfi</groupId>
<artifactId>mixins</artifactId>
<version>${project.version}</version>
<version>${tinfi.version}</version>
<classifier>sources</classifier>
</dependency>
<dependency> <!-- Artifact specified in the <mixins> tag -->
<dependency><!-- Artifact specified in the <mixins> tag -->
<groupId>org.objectweb.fractal.julia</groupId>
<artifactId>julia-mixins</artifactId>
<version>2.5.2</version>
<version>${julia-mixins.version}</version>
<classifier>sources</classifier>
</dependency>
</dependencies>
......@@ -48,11 +48,9 @@
<plugins>
<plugin>
<groupId>
org.objectweb.fractal.fractaladl.juliac.plugin
</groupId>
<groupId>org.objectweb.fractal.fractaladl.juliac.plugin</groupId>
<artifactId>maven-juliac-plugin</artifactId>
<version>1.2</version>
<version>${juliac.version}</version>
<executions>
<execution>
<id>juliac-compile</id>
......@@ -70,16 +68,22 @@
<!-- - FCCompCtrlSourceCodeGenerator: component-based -->
<!-- ================================================= -->
<srcs>src/main/java</srcs>
<opt>
org.scorware.tinfi.juliac.FCOOCtrlSourceCodeGenerator
</opt>
<mixins>org.scorware.tinfi:mixins:${project.version}:sources org.objectweb.fractal.julia:julia-mixins:2.5.2:sources</mixins>
<opt>org.scorware.tinfi.juliac.FCOOCtrlSourceCodeGenerator</opt>
<mixins>org.scorware.tinfi:mixins:${tinfi.version}:sources org.objectweb.fractal.julia:julia-mixins:${julia-mixins.version}:sources</mixins>
<!-- opt>org.scorware.tinfi.juliac.FCCompCtrlSourceCodeGenerator</opt -->
<!-- mixins>org.scorware.tinfi:mixins:${project.version}:sources org.objectweb.fractal.julia:julia-mixins:${julia.version}:sources org.objectweb.fractal.julia:koch-mixins:${julia.version}:sources</mixins -->
<types>example.hw.HelloWorldAssembly</types>
<sysargs>julia.config=tinfi.cfg</sysargs>
<!-- verbose>true</verbose -->
</configuration>
<dependencies>
<dependency>
<groupId>org.scorware.tinfi</groupId>
<artifactId>mixins</artifactId>
<version>${tinfi.version}</version>
<classifier>sources</classifier>
</dependency>
</dependencies>
</plugin>
</plugins>
</build>
......
......@@ -17,67 +17,54 @@
<packaging>jar</packaging>
<dependencies>
<dependency>
<groupId>org.scorware.assembly</groupId>
<artifactId>factory</artifactId>
<version>${project.version}</version>
</dependency>
<dependency><!-- Artifact specified in the <mixins> tag -->
<groupId>org.scorware.tinfi</groupId>
<artifactId>mixins</artifactId>
<version>${tinfi.version}</version>
<classifier>sources</classifier>
</dependency>
<dependency><!-- Artifact specified in the <mixins> tag -->
<groupId>org.objectweb.fractal.julia</groupId>
<artifactId>julia-mixins</artifactId>
<version>${julia-mixins.version}</version>
<classifier>sources</classifier>
</dependency>
</dependencies>
<build>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<configuration>
<source>1.5</source>
<target>1.5</target>
</configuration>
</plugin>
<plugin>
<groupId>
org.objectweb.fractal.fractaladl.juliac.plugin
</groupId>
<artifactId>maven-juliac-plugin</artifactId>
<version>1.2</version>
<groupId>org.scorware.assembly</groupId>
<artifactId>generate-factory</artifactId>
<version>${project.version}</version>
<executions>
<execution>
<id>juliac-compile</id>
<phase>process-sources</phase>
<id>generate-factory</id>
<phase>generate-sources</phase>
<goals>
<goal>compile</goal>
</goals>
</execution>
</executions>
<configuration>
<opt>
org.scorware.tinfi.juliac.FCOOCtrlSourceCodeGenerator
</opt>
<srcs>src/main/resources src/main/java</srcs>
<mixins> org.scorware.tinfi:mixins:1.0-SNAPSHOT:sources org.objectweb.fractal.julia:julia-mixins:2.5.2:sources </mixins>
<types>${client.adl}</types>
<sysargs>julia.config=tinfi.cfg</sysargs>
<fractaladl.backend>
org.objectweb.fractal.bf.adl.MyStaticFractalBackend
</fractaladl.backend>
<verbose>true</verbose>
<srcs>src/main/java src/main/resources</srcs>
<mixins>org.scorware.tinfi:mixins:${tinfi.version}:sources org.objectweb.fractal.julia:julia-mixins:${julia-mixins.version}:sources</mixins>
<composite>example/hw/HelloWorldWS</composite>
</configuration>
<dependencies>
<dependency>
<groupId>org.scorware.tinfi</groupId>
<artifactId>mixins</artifactId>
<version>1.0-SNAPSHOT</version>
<classifier>sources</classifier>
</dependency>
<dependency>
<groupId>org.objectweb.fractal.julia</groupId>
<artifactId>julia-mixins</artifactId>
<version>2.5.2</version>
<classifier>sources</classifier>
</dependency>
<dependency>
<groupId>org.objectweb.fractal.bf</groupId>
<artifactId>adl</artifactId>
<version>0.1-SNAPSHOT</version>
</dependency>
<dependency>
<groupId>
org.objectweb.fractal.bf.connectors
</groupId>
<groupId>org.objectweb.fractal.bf.connectors</groupId>
<artifactId>soap-cxf</artifactId>
<version>0.1-SNAPSHOT</version>
</dependency>
......@@ -93,19 +80,6 @@
</build>
<dependencies>
<dependency>
<groupId>org.scorware.assembly</groupId>
<artifactId>factory</artifactId>
<version>1.0-SNAPSHOT</version>
</dependency>
<dependency>
<groupId>org.scorware.tinfi.examples</groupId>
<artifactId>helloworld</artifactId>
<version>1.0-SNAPSHOT</version>
</dependency>
</dependencies>
<properties>
<client.adl>example.hw.HelloWorldWS</client.adl>
<fractaladl.itf>r</fractaladl.itf>
......
package example.hw;
import org.osoa.sca.annotations.Init;
import org.osoa.sca.annotations.Reference;
public class ClientImpl implements Runnable {
public ClientImpl() {
System.err.println("CLIENT created");
}
@Init
public void init() {
System.err.println("CLIENT initialized");
}
public void run() {
s.print("hello world");
}
@Reference
public Service s;
}
\ No newline at end of file
package example.hw;
import org.osoa.sca.annotations.Property;
public class ServerImpl implements Service {
private String header = "->";
private int count = 1;
public ServerImpl() {
System.err.println("SERVER created");
}
public void print(final String msg) {
new Exception() {
private static final long serialVersionUID = 2182742162070453637L;
public String toString() {
return "Server: print method called";
}
}.printStackTrace();
System.err.println("Server: begin printing...");
for (int i = 0 ; i < (count) ; ++i) {
System.err.println(((header) + msg));
}
System.err.println("Server: print done.");
}
public String getHeader() {
return header;
}
@Property
public void setHeader(final String header) {
this.header = header;
}
public int getCount() {
return count;
}
@Property
public void setCount(final int count) {
this.count = count;
}
}
\ No newline at end of file
package example.hw;
public interface Service {
void print(String msg);
}
\ No newline at end of file
......@@ -18,28 +18,18 @@
<dependency>
<groupId>org.scorware.assembly</groupId>
<artifactId>factory</artifactId>
<version>1.0-SNAPSHOT</version>
</dependency>
<dependency><!-- Needed in all cases -->
<groupId>org.scorware.tinfi</groupId>
<artifactId>compiler</artifactId>
<version>${project.version}</version>
</dependency>
<dependency><!-- Needed in all cases -->
<groupId>org.objectweb.fractal.fractaladl.juliac</groupId>
<artifactId>runtime</artifactId>
<version>1.2</version>
</dependency>
<dependency><!-- Artifact specified in the <mixins> tag -->
<groupId>org.scorware.tinfi</groupId>
<artifactId>mixins</artifactId>
<version>${project.version}</version>
<version>${tinfi.version}</version>
<classifier>sources</classifier>
</dependency>
<dependency><!-- Artifact specified in the <mixins> tag -->
<groupId>org.objectweb.fractal.julia</groupId>
<artifactId>julia-mixins</artifactId>
<version>2.5.2</version>
<version>${julia-mixins.version}</version>
<classifier>sources</classifier>
</dependency>
</dependencies>
......@@ -48,23 +38,12 @@
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-compiler-plugin</artifactId>
<configuration>
<source>1.5</source>
<target>1.5</target>
</configuration>
</plugin>
<plugin>
<groupId>
org.objectweb.fractal.fractaladl.juliac.plugin
</groupId>
<artifactId>maven-juliac-plugin</artifactId>
<version>1.2</version>
<groupId>org.scorware.assembly</groupId>
<artifactId>generate-factory</artifactId>
<version>${project.version}</version>
<executions>
<execution>
<id>juliac-compile</id>
<id>generate-factory</id>
<phase>generate-sources</phase>
<goals>
<goal>compile</goal>
......@@ -72,23 +51,11 @@
</execution>
</executions>
<configuration>
<!-- ================================================= -->
<!-- Choose one of the following for SCA components -->
<!-- with a control membrane: -->
<!-- - FCOOCtrlSourceCodeGenerator: object-oriented -->
<!-- - FCCompCtrlSourceCodeGenerator: component-based -->
<!-- ================================================= -->
<srcs>src/main/java</srcs>
<opt>org.scorware.tinfi.juliac.FCOOCtrlSourceCodeGenerator</opt>
<mixins>org.scorware.tinfi:mixins:${project.version}:sources org.objectweb.fractal.julia:julia-mixins:2.5.2:sources</mixins>
<!-- opt>org.scorware.tinfi.juliac.FCCompCtrlSourceCodeGenerator</opt -->
<!-- mixins>org.scorware.tinfi:mixins:${project.version}:sources org.objectweb.fractal.julia:julia-mixins:${julia.version}:sources org.objectweb.fractal.julia:koch-mixins:${julia.version}:sources</mixins -->
<types>example.hw.HelloWorld</types>
<sysargs>julia.config=tinfi.cfg</sysargs>
<!-- verbose>true</verbose -->
<srcs>src/main/java src/main/resources</srcs>
<mixins>org.scorware.tinfi:mixins:${tinfi.version}:sources org.objectweb.fractal.julia:julia-mixins:${julia-mixins.version}:sources</mixins>
<composite>helloworld</composite>
</configuration>
</plugin>
</plugins>
</build>
......
......@@ -38,7 +38,7 @@
org.objectweb.fractal.fractaladl.juliac.plugin
</groupId>
<artifactId>maven-juliac-plugin</artifactId>
<version>1.2</version>
<version>${juliac.version}</version>
<executions>
<execution>
<id>juliac-compile</id>
......@@ -53,7 +53,7 @@
org.scorware.tinfi.juliac.FCOOCtrlSourceCodeGenerator
</opt>
<srcs>src/main/resources src/main/java</srcs>
<mixins> org.scorware.tinfi:mixins:1.0-SNAPSHOT:sources org.objectweb.fractal.julia:julia-mixins:2.5.2:sources </mixins>
<mixins> org.scorware.tinfi:mixins:${tinfi.version}:sources org.objectweb.fractal.julia:julia-mixins:${julia-mixins.version}:sources </mixins>
<types>${client.adl}</types>
<sysargs>julia.config=tinfi.cfg</sysargs>
<fractaladl.backend>
......@@ -78,13 +78,13 @@
<dependency><!-- Artifact specified in the <mixins> tag -->
<groupId>org.scorware.tinfi</groupId>
<artifactId>mixins</artifactId>
<version>${project.version}</version>
<version>${tinfi.version}</version>
<classifier>sources</classifier>
</dependency>
<dependency><!-- Artifact specified in the <mixins> tag -->
<groupId>org.objectweb.fractal.julia</groupId>
<artifactId>julia-mixins</artifactId>
<version>2.5.2</version>
<version>${julia-mixins.version}</version>
<classifier>sources</classifier>
</dependency>
<dependency>
......@@ -95,7 +95,7 @@
<dependency><!-- Needed in all cases -->
<groupId>org.scorware.tinfi</groupId>
<artifactId>compiler</artifactId>
<version>${project.version}</version>
<version>${tinfi.version}</version>
</dependency>
<dependency>
<groupId>org.scorware.assembly</groupId>
......
......@@ -2,11 +2,16 @@
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
<parent>
<groupId>org.scorware.assembly</groupId>
<artifactId>parent</artifactId>
<version>1.0-SNAPSHOT</version>
</parent>
<modelVersion>4.0.0</modelVersion>
<groupId>org.scorware.assembly.example</groupId>
<artifactId>parent</artifactId>
<packaging>pom</packaging>
<version>1.0-SNAPSHOT</version>
<name>Assembly Factory Examples</name>
......@@ -17,8 +22,8 @@
<module>helloworld</module>
<module>helloworld-composite</module>
<module>helloworld-ws</module>
<module>forge</module>
<module>meteo</module>
<!-- <module>forge</module> -->
<!-- <module>meteo</module> -->
</modules>
<profiles>
......@@ -79,12 +84,12 @@
org.objectweb.fractal.fractaladl.juliac
</groupId>
<artifactId>runtime</artifactId>
<version>1.2</version>
<version>${juliac.version}</version>
</dependency>
<dependency>
<groupId>org.scorware.assembly</groupId>
<artifactId>factory</artifactId>
<version>1.0-SNAPSHOT</version>
<version>${project.version}</version>
</dependency>
<dependency>
<groupId>
......
......@@ -49,7 +49,7 @@
org.objectweb.fractal.fractaladl.juliac.plugin
</groupId>
<artifactId>maven-juliac-plugin</artifactId>
<version>1.2</version>
<version>${juliac.version}</version>
<executions>
<execution>
<id>juliac-compile</id>
......@@ -63,7 +63,7 @@
<opt>OO</opt>
<srcs>target/generated-sources/spoon</srcs>
<mixins>
org.objectweb.fractal.julia:julia-mixins:2.5.2:sources
org.objectweb.fractal.julia:julia-mixins:${julia-mixins.version}:sources
</mixins>
<types>
org.scorware.assembly.Frascati
......@@ -103,7 +103,7 @@
org.objectweb.fractal.fractaladl.juliac.plugin
</groupId>
<artifactId>maven-juliac-plugin</artifactId>
<version>1.2</version>
<version>${juliac.version}</version>
<executions>
<execution>
<id>juliac-compile</id>
......@@ -117,7 +117,7 @@
<opt>OO</opt>
<srcs>target/generated-sources/spoon</srcs>
<mixins>
org.objectweb.fractal.julia:julia-mixins:2.5.2:sources
org.objectweb.fractal.julia:julia-mixins:${julia-mixins.version}:sources
</mixins>
<types>
org.scorware.assembly.AssemblyFactoryRunnable
......@@ -196,7 +196,7 @@
org.objectweb.fractal.fractaladl.juliac
</groupId>
<artifactId>runtime</artifactId>
<version>1.2</version>
<version>${juliac.version}</version>
</dependency>
</dependencies>
</profile>
......@@ -249,7 +249,7 @@
<dependency>
<groupId>org.scorware.tinfi</groupId>
<artifactId>runtime</artifactId>
<version>${project.version}</version>
<version>${tinfi.version}</version>
</dependency>
<dependency>
......@@ -278,7 +278,7 @@
<dependency>
<groupId>org.objectweb.fractal.julia</groupId>
<artifactId>julia-mixins</artifactId>
<version>2.5.2</version>
<version>${julia-mixins.version}</version>
<classifier>sources</classifier>
</dependency>
......
############################################################
# Default Logging Configuration File
#
# You can use a different file by specifying a filename
# with the java.util.logging.config.file system property.
# For example java -Djava.util.logging.config.file=myfile
############################################################
############################################################
# Global properties
############################################################
# "handlers" specifies a comma separated list of log Handler
# classes. These handlers will be installed during VM startup.
# Note that these classes must be on the system classpath.
# By default we only configure a ConsoleHandler, which will only
# show messages at the INFO and above levels.
handlers= java.util.logging.ConsoleHandler
# To also add the FileHandler, use the following line instead.
#handlers= java.util.logging.FileHandler, java.util.logging.ConsoleHandler
# Default global logging level.
# This specifies which kinds of events are logged across
# all loggers. For any given facility this global level
# can be overriden by a facility specific level
# Note that the ConsoleHandler also has a separate level
# setting to limit messages printed to the console.
.level = OFF
############################################################
# Handler specific properties.
# Describes specific configuration info for Handlers.
############################################################
# default file output is in user's home directory.
java.util.logging.FileHandler.pattern = %h/java%u.log
java.util.logging.FileHandler.limit = 50000
java.util.logging.FileHandler.count = 1
java.util.logging.FileHandler.formatter = java.util.logging.XMLFormatter
# Limit the message that are printed on the console to INFO and above.
java.util.logging.ConsoleHandler.level = OFF
java.util.logging.ConsoleHandler.formatter = java.util.logging.SimpleFormatter
############################################################
# Facility specific properties.
# Provides extra control for each logger.
############################################################
# For example, set the com.xyz.foo logger to only log SEVERE
# messages: com.xyz.foo.level = SEVERE
spoonlet.level = OFF
spoonlet.fractal.level = OFF
spoonlet.fractaladl.level = OFF
<?xml version="1.0" encoding="UTF-8"?>
<project>
<parent>
<artifactId>parent</artifactId>
<groupId>org.scorware.assembly</groupId>
<version>1.0-SNAPSHOT</version>
</parent>
<modelVersion>4.0.0</modelVersion>
<groupId>org.scorware.assembly</groupId>
<artifactId>generate-factory</artifactId>