/** * Returns the {@link Factory} interface of the given component. * * @param component a component. * @return the {@link Factory} interface of the given component. * @throws NoSuchInterfaceException if there is no such interface. */ public static Factory getFactory (final Component component) throws NoSuchInterfaceException { return (Factory)component.getFcInterface("factory"); }
/** * Return the <code>itfName</code> server interface of type <code>cl</code> * for the specified component. */ public static <T> T getService( Component c, Class<T> cl, String itfName ) throws NoSuchInterfaceException { T s = (T) c.getFcInterface(itfName); return s; }
/** * Returns the {@link AttributeController} interface of the given component. * * @param component a component. * @return the {@link AttributeController} interface of the given component. * @throws NoSuchInterfaceException if there is no such interface. */ public static AttributeController getAttributeController ( final Component component) throws NoSuchInterfaceException { return (AttributeController)component.getFcInterface("attribute-controller"); }
/** * Returns the {@link BindingController} interface of the given component. * * @param component a component. * @return the {@link BindingController} interface of the given component. * @throws NoSuchInterfaceException if there is no such interface. */ public static BindingController getBindingController ( final Component component) throws NoSuchInterfaceException { return (BindingController)component.getFcInterface("binding-controller"); }
/** * Returns the {@link GenericFactory} interface of the given component. * * @param component a component. * @return the {@link GenericFactory} interface of the given component. * @throws NoSuchInterfaceException if there is no such interface. */ public static GenericFactory getGenericFactory (final Component component) throws NoSuchInterfaceException { return (GenericFactory)component.getFcInterface("generic-factory"); }
public java.lang.Object getFcInterface(final java.lang.String arg0) throws org.objectweb.fractal.api.NoSuchInterfaceException { if ( impl == null ) { throw new java.lang.NullPointerException("Trying to invoke a method on a client or server interface whose complementary interface is not bound."); } java.lang.Object ret = impl.getFcInterface(arg0); return ret; }
public Execution getParentExecution() throws CoreException { Execution res = null; try { if (this.parentExecution != null) { res = (Execution) this.parentExecution .getFcInterface("service"); } } catch (final NoSuchInterfaceException e) { throw new CoreException(e); } return res; }
public Engine getEngine() throws CoreException { Engine res = null; try { if (this.engineComponent != null) { res = (Engine) this.engineComponent.getFcInterface("service"); } } catch (final NoSuchInterfaceException e) { throw new CoreException(e); } return res; }
public List<Receiver> getReceivers() throws CoreException { final List<Receiver> res = new ArrayList<Receiver>(); for (final Component comp : this.receivers) { try { res.add((Receiver) comp.getFcInterface("service")); } catch (final NoSuchInterfaceException e) { throw new CoreException(e); } } return res; }
public Execution getParentExecution() throws CoreException { Execution res = null; try { if (this.parentExecution != null) { res = (Execution) this.parentExecution .getFcInterface("service"); } } catch (final NoSuchInterfaceException e) { throw new CoreException(e); } return res; }
public List<Receiver> getReceivers() throws CoreException { final List<Receiver> res = new ArrayList<Receiver>(); for (final Component comp : this.receivers) { try { res.add((Receiver) comp.getFcInterface("service")); } catch (final NoSuchInterfaceException e) { throw new CoreException(e); } } return res; }
public List<Sender> getSenders() throws CoreException { final List<Sender> res = new ArrayList<Sender>(); for (final Component comp : this.senders) { try { res.add((Sender) comp.getFcInterface("service")); } catch (final NoSuchInterfaceException e) { throw new CoreException(e); } } return res; }
private void launchStopActions() { Component lcm = FractalHelper.getRecursiveComponentByName(petalsContentController, "LifeCycleManagerImpl"); if (lcm != null) { try { LifeCycleManager manager = (LifeCycleManager) lcm.getFcInterface("service"); manager.onStop(); } catch (NoSuchInterfaceException e) { } } }
/** * @see org.ow2.frascati.tinfi.control.binding.BasicBindingControllerMixin#lookupFc(java.lang.String) */ private Object lookupFc$0(final String clientItfName) throws NoSuchInterfaceException { ComponentInterface ci = ((ComponentInterface)(weaveableC.getFcInterface(clientItfName))); Interceptor interceptor = ((Interceptor)(ci.getFcItfImpl())); Object dst = interceptor.getFcItfDelegate(); return dst; }
@LifeCycle(on = LifeCycleType.START) public void start() throws Exception { log = new LoggingUtil(logger); log.call(); exchangeQueuesMap = new Hashtable<String, ArrayBlockingQueue<MessageExchange>>(); localTransportProtocol = (TransportProtocol) localTransporterComponent .getFcInterface("service"); }
public ExecutionEnvironmentTest getExecutionEnvironmentTest() throws CoreException { ExecutionEnvironmentTest res = null; try { Component execEnvComp = FractalHelper.getFractalHelper().getParent(this.getComponent()); res = (ExecutionEnvironmentTest) execEnvComp.getFcInterface("service"); } catch (NoSuchInterfaceException e) { throw new CoreException(e); } return res; } }
/** * @see org.ow2.frascati.tinfi.control.binding.InterfaceBindingControllerMixin#unbindFc(java.lang.String) */ private void unbindFc$2(final java.lang.String clientItfName) throws org.objectweb.fractal.api.NoSuchInterfaceException, org.objectweb.fractal.api.control.IllegalBindingException, org.objectweb.fractal.api.control.IllegalLifeCycleException { unbindFc$3(clientItfName); org.objectweb.fractal.julia.ComponentInterface ci = ((org.objectweb.fractal.julia.ComponentInterface) (weaveableC.getFcInterface(clientItfName))); org.objectweb.fractal.julia.Interceptor interceptor = ((org.objectweb.fractal.julia.Interceptor) (ci.getFcItfImpl())); interceptor.setFcItfDelegate(null); weaveableSCACC.unsetReferenceValue(clientItfName); }
public ExecutionEnvironmentTest getExecutionEnvironmentTest() throws CoreException { ExecutionEnvironmentTest res = null; try { Component execEnvComp = FractalHelper.getFractalHelper().getParent(this.getComponent()); res = (ExecutionEnvironmentTest) execEnvComp.getFcInterface("service"); } catch (NoSuchInterfaceException e) { throw new CoreException(e); } return res; }
public ExternalEnvironment getExternalEnvironment() throws CoreException { ExternalEnvironment res = null; try { final Component externalEnvironmentComp = FractalHelper .getFractalHelper().getParent(this.getComponent()); res = (ExternalEnvironment) externalEnvironmentComp .getFcInterface("service"); } catch (final NoSuchInterfaceException e) { throw new CoreException(e); } return res; }
/** * @see org.ow2.frascati.tinfi.control.binding.InterfaceBindingControllerMixin#bindFc(java.lang.String,java.lang.Object) */ private void bindFc$1(final java.lang.String clientItfName, final java.lang.Object serverItf) throws org.objectweb.fractal.api.NoSuchInterfaceException, org.objectweb.fractal.api.control.IllegalBindingException, org.objectweb.fractal.api.control.IllegalLifeCycleException { bindFc$2(clientItfName, serverItf); org.objectweb.fractal.julia.ComponentInterface ci = ((org.objectweb.fractal.julia.ComponentInterface) (weaveableC.getFcInterface(clientItfName))); org.objectweb.fractal.julia.Interceptor interceptor = ((org.objectweb.fractal.julia.Interceptor) (ci.getFcItfImpl())); interceptor.setFcItfDelegate(serverItf); org.ow2.frascati.tinfi.TinfiComponentOutInterface<?> tci = ((org.ow2.frascati.tinfi.TinfiComponentOutInterface<?>) (ci)); org.oasisopen.sca.ServiceReference<?> sr = tci.getServiceReference(); weaveableSCACC.setReferenceValue(clientItfName, sr); }