/** * Calls the overriden method and returns the corresponding {@link * Interceptor#getFcItfDelegate getFcItfDelegate} (if the result is an {@link * Interceptor}). * * @param clientItfName the name of a client interface of the component to * which this interface belongs. * @return the server interface to which the given interface is bound, or <tt> * null</tt> if it is not bound. * @throws NoSuchInterfaceException if the component to which this interface * belongs does not have a client interface whose name is equal to the * given name. */ public Object lookupFc (final String clientItfName) throws NoSuchInterfaceException { Object o = _super_lookupFc(clientItfName); if (o instanceof Interceptor) { // skips the output interceptor, if there is one o = ((Interceptor)o).getFcItfDelegate(); } return o; }
/** * Gets the interceptor of the given client interface, updates its {@link * Interceptor#getFcItfDelegate getFcItfDelegate}, and then calls the * overriden method (if there is an interceptor for the client interface). * * @param clientItfName the name of a client interface of the component to * which this interface belongs. * @throws NoSuchInterfaceException if there is no such client interface. * @throws IllegalBindingException if the binding cannot be removed. * @throws IllegalLifeCycleException if this component has a {@link * org.objectweb.fractal.api.control.LifeCycleController} interface, but it is not in an appropriate state * to perform this operation. */ public void unbindFc (final String clientItfName) throws NoSuchInterfaceException, IllegalBindingException, IllegalLifeCycleException { Object o = _this_weaveableC.getFcInterface(clientItfName); if (o instanceof ComponentInterface) { Object next = ((ComponentInterface)o).getFcItfImpl(); if (next instanceof Interceptor) { ((Interceptor)next).setFcItfDelegate(null); } else { ((ComponentInterface)o).setFcItfImpl(null); } } _super_unbindFc(clientItfName); }
o = serverItf; _super_bindFc(clientItfName, o);
/** * Gets the interceptor of the given client interface, updates its {@link * Interceptor#getFcItfDelegate getFcItfDelegate}, and then calls the * overriden method (if there is an interceptor for the client interface). * * @param clientItfName the name of a client interface of the component to * which this interface belongs. * @throws NoSuchInterfaceException if there is no such client interface. * @throws IllegalBindingException if the binding cannot be removed. * @throws IllegalLifeCycleException if this component has a {@link * org.objectweb.fractal.api.control.LifeCycleController} interface, but it is not in an appropriate state * to perform this operation. */ public void unbindFc (final String clientItfName) throws NoSuchInterfaceException, IllegalBindingException, IllegalLifeCycleException { Object o = _this_weaveableC.getFcInterface(clientItfName); if (o instanceof ComponentInterface) { Object next = ((ComponentInterface)o).getFcItfImpl(); if (next instanceof Interceptor) { ((Interceptor)next).setFcItfDelegate(null); } else { ((ComponentInterface)o).setFcItfImpl(null); } } _super_unbindFc(clientItfName); }
o = serverItf; _super_bindFc(clientItfName, o);
/** * Calls the overriden method and returns the corresponding {@link * Interceptor#getFcItfDelegate getFcItfDelegate} (if the result is an {@link * Interceptor}). * * @param clientItfName the name of a client interface of the component to * which this interface belongs. * @return the server interface to which the given interface is bound, or <tt> * null</tt> if it is not bound. * @throws NoSuchInterfaceException if the component to which this interface * belongs does not have a client interface whose name is equal to the * given name. */ public Object lookupFc (final String clientItfName) throws NoSuchInterfaceException { Object o = _super_lookupFc(clientItfName); if (o instanceof Interceptor) { // skips the output interceptor, if there is one o = ((Interceptor)o).getFcItfDelegate(); } return o; }