All Downloads are FREE. Search and download functionalities are using the official Maven repository.

juliac.generated.compositeFC1dab967 Maven / Gradle / Ivy

/*
 * Generated by: org.objectweb.fractal.juliac.opt.oo.InitializerOOCtrlClassGenerator
 * on: Thu Jun 18 16:47:41 CEST 2009
 */

package juliac.generated;


public class compositeFC1dab967
implements org.objectweb.fractal.juliac.runtime.Factory {

  public org.objectweb.fractal.api.Type getFcInstanceType()  {
    try {
      return new org.objectweb.fractal.julia.type.BasicComponentType( new org.objectweb.fractal.api.type.InterfaceType[]{new org.objectweb.fractal.julia.type.BasicInterfaceType("service","org.objectweb.fractal.bf.connectors.Service",false,false,false),} );
    }
    catch( org.objectweb.fractal.api.factory.InstantiationException ie ) {
      throw new org.objectweb.fractal.juliac.runtime.RuntimeException(ie);
    }
  }

  public Object getFcControllerDesc()  {
      return "composite";
  }

  public Object getFcContentDesc()  {
      return null;
  }

  public Object newFcContent()  {
    Object content = null;
    return content;
  }

  public org.objectweb.fractal.api.Component newFcInstance() throws org.objectweb.fractal.api.factory.InstantiationException  {
    Object content = newFcContent();
    return newFcInstance(content);
  }

  public org.objectweb.fractal.api.Component newFcInstance(Object content) throws org.objectweb.fractal.api.factory.InstantiationException  {
    org.objectweb.fractal.julia.InitializationContext ic = new org.objectweb.fractal.julia.InitializationContext();
    ic.controllers = new java.util.ArrayList();
    ic.interfaces = new java.util.HashMap();
    ic.internalInterfaces = new java.util.HashMap();
    ic.interfaces.put("/content",content);
    ic.interfaces.put("/controllerDesc","composite");
    ic.content = content;
    Object ctrl = null;
    org.objectweb.fractal.api.Component compctrl = null;
    ic.controllers.add(ctrl = new juliac.generated.ComponentImpl());
    if( ctrl instanceof org.objectweb.fractal.api.Component) {compctrl=(org.objectweb.fractal.api.Component)ctrl;}
    ic.controllers.add(ctrl = new juliac.generated.CompositeBindingControllerImpl());
    if( ctrl instanceof org.objectweb.fractal.api.Component) {compctrl=(org.objectweb.fractal.api.Component)ctrl;}
    ic.controllers.add(ctrl = new juliac.generated.ContentControllerImpl());
    if( ctrl instanceof org.objectweb.fractal.api.Component) {compctrl=(org.objectweb.fractal.api.Component)ctrl;}
    ic.controllers.add(ctrl = new juliac.generated.SuperControllerImpl());
    if( ctrl instanceof org.objectweb.fractal.api.Component) {compctrl=(org.objectweb.fractal.api.Component)ctrl;}
    ic.controllers.add(ctrl = new juliac.generated.CompositeLifeCycleControllerImpl());
    if( ctrl instanceof org.objectweb.fractal.api.Component) {compctrl=(org.objectweb.fractal.api.Component)ctrl;}
    ic.controllers.add(ctrl = new juliac.generated.NameControllerImpl());
    if( ctrl instanceof org.objectweb.fractal.api.Component) {compctrl=(org.objectweb.fractal.api.Component)ctrl;}
    Object intercept = null;
    intercept = compctrl;
    org.objectweb.fractal.api.Interface proxy = new org.objectweb.fractal.api.ComponentFcItf(compctrl,"component",new org.objectweb.fractal.julia.type.BasicInterfaceType("component","org.objectweb.fractal.api.Component",false,false,false),false,intercept);
    org.objectweb.fractal.api.Component proxyForCompCtrl = (org.objectweb.fractal.api.Component) proxy;
    ic.interfaces.put("component",proxy);
    for( int i=0 ; i < ic.controllers.size() ; i++ ) {
      ctrl = ic.controllers.get(i);
      if( ctrl instanceof org.objectweb.fractal.api.control.BindingController ) {
        break;
      }
      ctrl = null;
    }
    if( ctrl == null ) {
      if( content instanceof org.objectweb.fractal.api.control.BindingController) {
        ctrl = content;
      }
      else {
        throw new org.objectweb.fractal.api.factory.InstantiationException("No such controller implementing org.objectweb.fractal.api.control.BindingController");
      }
    }
    intercept = ctrl;
    proxy = new org.objectweb.fractal.api.control.BindingControllerFcItf(proxyForCompCtrl,"binding-controller",new org.objectweb.fractal.julia.type.BasicInterfaceType("binding-controller","org.objectweb.fractal.api.control.BindingController",false,false,false),false,intercept);
    ic.interfaces.put("binding-controller",proxy);
    for( int i=0 ; i < ic.controllers.size() ; i++ ) {
      ctrl = ic.controllers.get(i);
      if( ctrl instanceof org.objectweb.fractal.api.control.ContentController ) {
        break;
      }
      ctrl = null;
    }
    if( ctrl == null ) {
      if( content instanceof org.objectweb.fractal.api.control.ContentController) {
        ctrl = content;
      }
      else {
        throw new org.objectweb.fractal.api.factory.InstantiationException("No such controller implementing org.objectweb.fractal.api.control.ContentController");
      }
    }
    intercept = ctrl;
    proxy = new org.objectweb.fractal.api.control.ContentControllerFcItf(proxyForCompCtrl,"content-controller",new org.objectweb.fractal.julia.type.BasicInterfaceType("content-controller","org.objectweb.fractal.api.control.ContentController",false,false,false),false,intercept);
    ic.interfaces.put("content-controller",proxy);
    for( int i=0 ; i < ic.controllers.size() ; i++ ) {
      ctrl = ic.controllers.get(i);
      if( ctrl instanceof org.objectweb.fractal.julia.control.content.SuperControllerNotifier ) {
        break;
      }
      ctrl = null;
    }
    if( ctrl == null ) {
      if( content instanceof org.objectweb.fractal.julia.control.content.SuperControllerNotifier) {
        ctrl = content;
      }
      else {
        throw new org.objectweb.fractal.api.factory.InstantiationException("No such controller implementing org.objectweb.fractal.julia.control.content.SuperControllerNotifier");
      }
    }
    intercept = ctrl;
    proxy = new org.objectweb.fractal.julia.control.content.SuperControllerNotifierFcItf(proxyForCompCtrl,"super-controller",new org.objectweb.fractal.julia.type.BasicInterfaceType("super-controller","org.objectweb.fractal.julia.control.content.SuperControllerNotifier",false,false,false),false,intercept);
    ic.interfaces.put("super-controller",proxy);
    for( int i=0 ; i < ic.controllers.size() ; i++ ) {
      ctrl = ic.controllers.get(i);
      if( ctrl instanceof org.objectweb.fractal.julia.control.lifecycle.LifeCycleCoordinator ) {
        break;
      }
      ctrl = null;
    }
    if( ctrl == null ) {
      if( content instanceof org.objectweb.fractal.julia.control.lifecycle.LifeCycleCoordinator) {
        ctrl = content;
      }
      else {
        throw new org.objectweb.fractal.api.factory.InstantiationException("No such controller implementing org.objectweb.fractal.julia.control.lifecycle.LifeCycleCoordinator");
      }
    }
    intercept = ctrl;
    proxy = new org.objectweb.fractal.julia.control.lifecycle.LifeCycleCoordinatorFcItf(proxyForCompCtrl,"lifecycle-controller",new org.objectweb.fractal.julia.type.BasicInterfaceType("lifecycle-controller","org.objectweb.fractal.julia.control.lifecycle.LifeCycleCoordinator",false,false,false),false,intercept);
    ic.interfaces.put("lifecycle-controller",proxy);
    for( int i=0 ; i < ic.controllers.size() ; i++ ) {
      ctrl = ic.controllers.get(i);
      if( ctrl instanceof org.objectweb.fractal.api.control.NameController ) {
        break;
      }
      ctrl = null;
    }
    if( ctrl == null ) {
      if( content instanceof org.objectweb.fractal.api.control.NameController) {
        ctrl = content;
      }
      else {
        throw new org.objectweb.fractal.api.factory.InstantiationException("No such controller implementing org.objectweb.fractal.api.control.NameController");
      }
    }
    intercept = ctrl;
    proxy = new org.objectweb.fractal.api.control.NameControllerFcItf(proxyForCompCtrl,"name-controller",new org.objectweb.fractal.julia.type.BasicInterfaceType("name-controller","org.objectweb.fractal.api.control.NameController",false,false,false),false,intercept);
    ic.interfaces.put("name-controller",proxy);
    ic.type = new org.objectweb.fractal.julia.type.BasicComponentType( new org.objectweb.fractal.api.type.InterfaceType[]{new org.objectweb.fractal.julia.type.BasicInterfaceType("component","org.objectweb.fractal.api.Component",false,false,false),new org.objectweb.fractal.julia.type.BasicInterfaceType("binding-controller","org.objectweb.fractal.api.control.BindingController",false,false,false),new org.objectweb.fractal.julia.type.BasicInterfaceType("content-controller","org.objectweb.fractal.api.control.ContentController",false,false,false),new org.objectweb.fractal.julia.type.BasicInterfaceType("super-controller","org.objectweb.fractal.julia.control.content.SuperControllerNotifier",false,false,false),new org.objectweb.fractal.julia.type.BasicInterfaceType("lifecycle-controller","org.objectweb.fractal.julia.control.lifecycle.LifeCycleCoordinator",false,false,false),new org.objectweb.fractal.julia.type.BasicInterfaceType("name-controller","org.objectweb.fractal.api.control.NameController",false,false,false),new org.objectweb.fractal.julia.type.BasicInterfaceType("service","org.objectweb.fractal.bf.connectors.Service",false,false,false),} );
    intercept = content;
    proxy = new org.objectweb.fractal.bf.connectors.ServiceFcItf(proxyForCompCtrl,"service",new org.objectweb.fractal.julia.type.BasicInterfaceType("service","org.objectweb.fractal.bf.connectors.Service",false,false,false),false,intercept);
    ic.interfaces.put("service",proxy);
    proxy = new org.objectweb.fractal.bf.connectors.ServiceFcItf(proxyForCompCtrl,"service",new org.objectweb.fractal.julia.type.BasicInterfaceType("service","org.objectweb.fractal.bf.connectors.Service",true,false,false),true,intercept);
    ic.internalInterfaces.put("service",proxy);
    for( int i=0 ; i < ic.controllers.size() ; i++ ) {
      ctrl = ic.controllers.get(i);
      if( ctrl instanceof org.objectweb.fractal.julia.Controller ) {
        ((org.objectweb.fractal.julia.Controller)ctrl).initFcController(ic);
      }
    }
    return proxyForCompCtrl;
  }

}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy