1 31 package org.objectweb.proactive.core.component.type; 32 33 34 import org.apache.log4j.Logger; 35 36 import org.objectweb.fractal.api.factory.InstantiationException; 37 import org.objectweb.fractal.api.type.ComponentType; 38 import org.objectweb.fractal.api.type.InterfaceType; 39 import org.objectweb.fractal.api.type.TypeFactory; 40 41 42 50 public class ProActiveTypeFactory implements TypeFactory { 51 protected static Logger logger = Logger.getLogger(ProActiveTypeFactory.class.getName()); 52 53 static private ProActiveTypeFactory instance = null; 55 56 59 private ProActiveTypeFactory() { 60 super(); 61 } 62 63 static public ProActiveTypeFactory instance() { 64 if (instance == null) { 65 instance = new ProActiveTypeFactory(); 66 } 67 return instance; 68 } 69 70 73 public InterfaceType createFcItfType(String name, String signature, boolean isClient, boolean isOptional, 74 boolean isCollection) throws InstantiationException { 75 return new ProActiveInterfaceType(name, signature, isClient, isOptional, isCollection); 76 } 77 78 81 public ComponentType createFcType(InterfaceType[] interfaceTypes) throws InstantiationException { 82 return new ProActiveComponentType(interfaceTypes); 83 } 84 } | Popular Tags |