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

Move common helper methods in module commons.

Fix typo in class name.
parent 72d027f7
......@@ -16,7 +16,7 @@
<dependency>
<groupId>org.ow2.fractal.juliac</groupId>
<artifactId>juliac-tests-tools</artifactId>
<artifactId>juliac-commons</artifactId>
<version>${juliac.version}</version>
</dependency>
......
......@@ -4,7 +4,7 @@ import org.oasisopen.sca.annotation.Init;
import org.oasisopen.sca.annotation.Reference;
import org.oasisopen.sca.annotation.Service;
import org.objectweb.fractal.fraclet.extensions.Membrane;
import org.objectweb.fractal.juliac.test.Console;
import org.objectweb.fractal.juliac.commons.io.Console;
@Service(value=Runnable.class,names="r")
@Membrane(controller="scaCompositeWithContent")
......
......@@ -2,7 +2,7 @@ package example.hw;
import org.oasisopen.sca.annotation.Property;
import org.oasisopen.sca.annotation.Service;
import org.objectweb.fractal.juliac.test.Console;
import org.objectweb.fractal.juliac.commons.io.Console;
@Service(value=PrinterItf.class,names="s")
public class ServerImpl implements PrinterItf {
......
......@@ -23,8 +23,6 @@
package example.hw;
import java.io.IOException;
import junit.framework.TestCase;
import org.junit.Test;
......@@ -36,8 +34,8 @@ import org.objectweb.fractal.api.control.IllegalContentException;
import org.objectweb.fractal.api.control.IllegalLifeCycleException;
import org.objectweb.fractal.api.control.LifeCycleController;
import org.objectweb.fractal.api.factory.InstantiationException;
import org.objectweb.fractal.juliac.commons.io.Console;
import org.objectweb.fractal.juliac.runtime.Factory;
import org.objectweb.fractal.juliac.test.Console;
import org.objectweb.fractal.util.Fractal;
import org.ow2.frascati.tinfi.api.control.SCAPropertyController;
......@@ -57,7 +55,7 @@ public class HelloWorldTestCase extends TestCase {
ClassNotFoundException, InstantiationException, IllegalAccessException,
InstantiationException, java.lang.InstantiationException,
NoSuchInterfaceException, IllegalContentException,
IllegalLifeCycleException, IllegalBindingException, IOException {
IllegalLifeCycleException, IllegalBindingException {
// Load factory classes
Class<Factory> hwfcl =
......
......@@ -20,7 +20,7 @@
</dependency>
<dependency>
<groupId>org.ow2.fractal.juliac</groupId>
<artifactId>juliac-tests-tools</artifactId>
<artifactId>juliac-commons</artifactId>
<version>${juliac.version}</version>
</dependency>
......
......@@ -4,7 +4,7 @@ import org.oasisopen.sca.annotation.Init;
import org.oasisopen.sca.annotation.Reference;
import org.oasisopen.sca.annotation.Service;
import org.objectweb.fractal.fraclet.extensions.Membrane;
import org.objectweb.fractal.juliac.test.Console;
import org.objectweb.fractal.juliac.commons.io.Console;
@Service(value=Runnable.class,names="r")
@Membrane(controllerDesc=MySCAPrimitive.class)
......
......@@ -3,7 +3,7 @@ package example.hw;
import org.oasisopen.sca.annotation.Property;
import org.oasisopen.sca.annotation.Service;
import org.objectweb.fractal.fraclet.extensions.Membrane;
import org.objectweb.fractal.juliac.test.Console;
import org.objectweb.fractal.juliac.commons.io.Console;
@Service(value=PrinterItf.class,names="s")
@Membrane(controller="mySCAPrimitive") // ClientImpl must be processed first
......
......@@ -23,8 +23,6 @@
package example.hw;
import java.io.IOException;
import junit.framework.TestCase;
import org.junit.Test;
......@@ -36,8 +34,8 @@ import org.objectweb.fractal.api.control.IllegalContentException;
import org.objectweb.fractal.api.control.IllegalLifeCycleException;
import org.objectweb.fractal.api.control.LifeCycleController;
import org.objectweb.fractal.api.factory.InstantiationException;
import org.objectweb.fractal.juliac.commons.io.Console;
import org.objectweb.fractal.juliac.runtime.Factory;
import org.objectweb.fractal.juliac.test.Console;
import org.objectweb.fractal.util.Fractal;
import org.ow2.frascati.tinfi.api.control.SCAPropertyController;
......@@ -57,7 +55,7 @@ public class HelloWorldTestCase extends TestCase {
ClassNotFoundException, InstantiationException, IllegalAccessException,
InstantiationException, java.lang.InstantiationException,
NoSuchInterfaceException, IllegalContentException,
IllegalLifeCycleException, IllegalBindingException, IOException {
IllegalLifeCycleException, IllegalBindingException {
// Load factory classes
Class<Factory> hwfcl =
......
......@@ -46,8 +46,8 @@ import org.objectweb.fractal.julia.ComponentInterface;
import org.objectweb.fractal.julia.Controller;
import org.objectweb.fractal.julia.InitializationContext;
import org.objectweb.fractal.julia.Interceptor;
import org.objectweb.fractal.juliac.ipf.InjectionPoint;
import org.objectweb.fractal.juliac.ipf.CompositeInjectionPointHashMap;
import org.objectweb.fractal.juliac.commons.ipf.CompositeInjectionPointHashMap;
import org.objectweb.fractal.juliac.commons.ipf.InjectionPoint;
import org.ow2.frascati.tinfi.TinfiComponentOutInterface;
import org.ow2.frascati.tinfi.TinfiRuntimeException;
import org.ow2.frascati.tinfi.api.control.ContentInstantiationException;
......
......@@ -39,10 +39,10 @@ import org.objectweb.fractal.api.type.InterfaceType;
import org.objectweb.fractal.julia.ComponentInterface;
import org.objectweb.fractal.julia.Controller;
import org.objectweb.fractal.julia.InitializationContext;
import org.objectweb.fractal.juliac.ipf.AnnotatedElementFilter;
import org.objectweb.fractal.juliac.ipf.ClassHelper;
import org.objectweb.fractal.juliac.ipf.Filter;
import org.objectweb.fractal.juliac.ipf.Filters;
import org.objectweb.fractal.juliac.commons.lang.ClassHelper;
import org.objectweb.fractal.juliac.commons.lang.reflect.AnnotatedElementFilter;
import org.objectweb.fractal.juliac.commons.util.function.Filter;
import org.objectweb.fractal.juliac.commons.util.function.Filters;
import org.objectweb.fractal.juliac.runtime.ClassLoaderFcItf;
import org.objectweb.fractal.juliac.runtime.ClassLoaderItf;
import org.objectweb.fractal.juliac.runtime.Juliac;
......
......@@ -33,12 +33,12 @@ import org.objectweb.fractal.julia.type.BasicInterfaceType;
import org.objectweb.fractal.juliac.api.JuliacModuleItf;
import org.objectweb.fractal.juliac.api.MembraneLoaderItf;
import org.objectweb.fractal.juliac.api.TypeGeneratorItf;
import org.objectweb.fractal.juliac.commons.lang.ClassHelper;
import org.objectweb.fractal.juliac.commons.lang.annotation.AnnotationHelper;
import org.objectweb.fractal.juliac.conf.JuliacConfig;
import org.objectweb.fractal.juliac.conf.JulietLoader;
import org.objectweb.fractal.juliac.desc.MembraneDesc;
import org.objectweb.fractal.juliac.desc.NoSuchControllerDescriptorException;
import org.objectweb.fractal.juliac.helper.ClassHelper;
import org.objectweb.fractal.juliac.ipf.AnnotationHelper;
import org.objectweb.fractal.juliac.proxy.InterfaceImplementationClassGenerator;
import org.objectweb.fractal.juliac.proxy.ProxyClassGeneratorItf;
import org.ow2.frascati.tinfi.opt.oo.CallBackInterfaceClassGenerator;
......@@ -204,7 +204,7 @@ extends org.objectweb.fractal.juliac.opt.comp.FCCompCtrlSourceCodeGenerator {
// ServiceReference and input interface implementations for callbacks
String signature = it.getFcItfSignature();
Class<?> cl = jc.loacClass(signature);
Class<?> cl = jc.loadClass(signature);
Annotation annot =
ClassHelper.getAnnotation(
cl,
......
......@@ -44,7 +44,7 @@ import org.ow2.frascati.tinfi.control.content.scope.StatelessScopeManager
import org.ow2.frascati.tinfi.oasis.ServiceReferenceImpl
import org.ow2.frascati.tinfi.osoa.ConversationScopeManager
import org.ow2.frascati.tinfi.osoa.RequestScopeManager
import org.objectweb.fractal.juliac.ipf.InjectionPoint
import org.objectweb.fractal.juliac.commons.ipf.InjectionPoint
/**
* Trait implementing the functionalities of the {@link
......
......@@ -25,9 +25,7 @@ package org.ow2.frascati.tinfi.control.intent
import java.lang.annotation.Annotation
import java.lang.reflect.Method
import scala.collection.mutable.HashMap
import org.objectweb.fractal.api.Component
import org.objectweb.fractal.api.Interface
import org.objectweb.fractal.api.`type`.InterfaceType
......@@ -35,15 +33,15 @@ import org.objectweb.fractal.julia.BasicControllerTrait
import org.objectweb.fractal.julia.ComponentInterface
import org.objectweb.fractal.julia.InitializationContext
import org.objectweb.fractal.julia.UseComponentTrait
import org.objectweb.fractal.juliac.ipf.AnnotatedElementFilter
import org.objectweb.fractal.juliac.ipf.ClassHelper
import org.objectweb.fractal.juliac.ipf.Filters
import org.objectweb.fractal.juliac.runtime.ClassLoaderFcItf
import org.objectweb.fractal.juliac.runtime.ClassLoaderItf
import org.objectweb.fractal.juliac.runtime.Juliac
import org.ow2.frascati.tinfi.TinfiComponentInterceptor
import org.ow2.frascati.tinfi.TinfiRuntimeException
import org.ow2.frascati.tinfi.api.IntentHandler
import org.objectweb.fractal.juliac.commons.lang.reflect.AnnotatedElementFilter
import org.objectweb.fractal.juliac.commons.util.function.Filters
import org.objectweb.fractal.juliac.commons.lang.ClassHelper
/**
* Trait implementing the {@link SCAIntentController} interface for scaPrimitive
......
......@@ -41,8 +41,8 @@ import org.objectweb.fractal.api.NoSuchInterfaceException;
import org.objectweb.fractal.api.control.ContentController;
import org.objectweb.fractal.api.control.IllegalLifeCycleException;
import org.objectweb.fractal.api.factory.InstantiationException;
import org.objectweb.fractal.juliac.ipf.DuplicationInjectionPointException;
import org.objectweb.fractal.juliac.ipf.InjectionPoint;
import org.objectweb.fractal.juliac.commons.ipf.DuplicationInjectionPointException;
import org.objectweb.fractal.juliac.commons.ipf.InjectionPoint;
import org.objectweb.fractal.util.Fractal;
import org.ow2.frascati.tinfi.api.control.SCAPropertyController;
import org.ow2.frascati.tinfi.control.content.ContentClassMetaData;
......@@ -104,7 +104,7 @@ public class PropertyTestCase {
*/
ContentClassMetaData ccmd =
ContentClassMetaData.get(PropertyImpl.class);
InjectionPoint ijp = ccmd.props.get("unannotatedFieldProp");
InjectionPoint<?> ijp = ccmd.props.get("unannotatedFieldProp");
ccmd.props.remove(ijp);
ijp = ccmd.props.get("setUnannotatedProp");
......
......@@ -31,8 +31,8 @@ import org.oasisopen.sca.ServiceReference;
import org.objectweb.fractal.api.type.InterfaceType;
import org.objectweb.fractal.juliac.Juliac;
import org.objectweb.fractal.juliac.api.TypeGeneratorItf;
import org.objectweb.fractal.juliac.commons.lang.ClassHelper;
import org.objectweb.fractal.juliac.desc.MembraneDesc;
import org.objectweb.fractal.juliac.helper.ClassHelper;
import org.objectweb.fractal.juliac.visit.BlockSourceCodeVisitor;
import org.objectweb.fractal.juliac.visit.ClassSourceCodeVisitor;
import org.ow2.frascati.tinfi.TinfiComponentOutInterface;
......@@ -76,7 +76,7 @@ extends ServerInterfaceClassGenerator {
/*
* Add type parameters if any.
*/
Class<?> proxycl = jc.loacClass(it.getFcItfSignature());
Class<?> proxycl = jc.loadClass(it.getFcItfSignature());
String[] tpnames = ClassHelper.getTypeParameterNames(proxycl);
if( tpnames.length != 0 ) {
String s = ClassHelper.getTypeParameterNamesSignature(tpnames);
......
......@@ -30,11 +30,11 @@ import org.oasisopen.sca.annotation.Callback;
import org.objectweb.fractal.api.type.InterfaceType;
import org.objectweb.fractal.julia.type.BasicInterfaceType;
import org.objectweb.fractal.juliac.api.TypeGeneratorItf;
import org.objectweb.fractal.juliac.commons.lang.ClassHelper;
import org.objectweb.fractal.juliac.commons.lang.annotation.AnnotationHelper;
import org.objectweb.fractal.juliac.conf.JuliacConfig;
import org.objectweb.fractal.juliac.conf.JulietLoader;
import org.objectweb.fractal.juliac.desc.MembraneDesc;
import org.objectweb.fractal.juliac.helper.ClassHelper;
import org.objectweb.fractal.juliac.ipf.AnnotationHelper;
import org.objectweb.fractal.juliac.proxy.InterfaceImplementationClassGenerator;
import org.objectweb.fractal.juliac.proxy.ProxyClassGeneratorItf;
......@@ -189,7 +189,7 @@ extends org.objectweb.fractal.juliac.opt.oo.FCOOCtrlSourceCodeGenerator {
// ServiceReference and input interface implementations for callbacks
String signature = it.getFcItfSignature();
Class<?> cl = jc.loacClass(signature);
Class<?> cl = jc.loadClass(signature);
Annotation annot =
ClassHelper.getAnnotation(
cl,
......
......@@ -26,7 +26,7 @@ package org.ow2.frascati.tinfi.opt.oo;
import java.lang.reflect.Method;
import org.objectweb.fractal.juliac.UClass;
import org.objectweb.fractal.juliac.helper.ClassHelper;
import org.objectweb.fractal.juliac.commons.lang.ClassHelper;
import org.objectweb.fractal.juliac.visit.BlockSourceCodeVisitor;
import org.objectweb.fractal.juliac.visit.ClassSourceCodeVisitor;
......
......@@ -28,8 +28,8 @@ import java.lang.reflect.Method;
import org.objectweb.fractal.api.type.InterfaceType;
import org.objectweb.fractal.juliac.Juliac;
import org.objectweb.fractal.juliac.commons.lang.ClassHelper;
import org.objectweb.fractal.juliac.desc.MembraneDesc;
import org.objectweb.fractal.juliac.helper.ClassHelper;
import org.objectweb.fractal.juliac.proxy.AbstractInterceptorSourceCodeGenerator;
import org.objectweb.fractal.juliac.visit.BlockSourceCodeVisitor;
import org.osoa.sca.annotations.EndsConversation;
......
......@@ -31,9 +31,9 @@ import org.objectweb.fractal.api.Interface;
import org.objectweb.fractal.api.type.InterfaceType;
import org.objectweb.fractal.juliac.Juliac;
import org.objectweb.fractal.juliac.UClass;
import org.objectweb.fractal.juliac.commons.lang.ClassHelper;
import org.objectweb.fractal.juliac.commons.lang.reflect.MethodHelper;
import org.objectweb.fractal.juliac.desc.MembraneDesc;
import org.objectweb.fractal.juliac.helper.ClassHelper;
import org.objectweb.fractal.juliac.helper.MethodHelper;
import org.objectweb.fractal.juliac.proxy.AbstractInterceptorSourceCodeGenerator;
import org.objectweb.fractal.juliac.visit.BlockSourceCodeVisitor;
import org.objectweb.fractal.juliac.visit.ClassSourceCodeVisitor;
......
......@@ -25,8 +25,8 @@ package org.ow2.frascati.tinfi.opt.oo;
import org.objectweb.fractal.api.type.InterfaceType;
import org.objectweb.fractal.juliac.Juliac;
import org.objectweb.fractal.juliac.commons.lang.ClassHelper;
import org.objectweb.fractal.juliac.desc.MembraneDesc;
import org.objectweb.fractal.juliac.helper.ClassHelper;
import org.objectweb.fractal.juliac.proxy.AbstractInterceptorSourceCodeGenerator;
import org.objectweb.fractal.juliac.visit.BlockSourceCodeVisitor;
import org.ow2.frascati.tinfi.TinfiComponentInterceptor;
......@@ -89,7 +89,7 @@ extends AbstractInterceptorSourceCodeGenerator {
/*
* Add type parameters if any.
*/
Class<?> proxycl = jc.loacClass(signature);
Class<?> proxycl = jc.loadClass(signature);
String[] tpnames = ClassHelper.getTypeParameterNames(proxycl);
if( tpnames.length != 0 ) {
String s = ClassHelper.getTypeParameterNamesSignature(tpnames);
......
Supports Markdown
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