Package org.jvnet.hk2.config

Examples of org.jvnet.hk2.config.ObservableBean.addListener()


        // embedded mode does not have manager-propertie in domain.xml
        if (configListener.managerProperties != null) {
            ObservableBean managerBean = (ObservableBean) ConfigSupport.getImpl(
                    configListener.managerProperties);
            managerBean.addListener(configListener);
        }

        if (serverConfig.getJavaConfig() != null) {
            ((ObservableBean)ConfigSupport.getImpl(
                    serverConfig.getJavaConfig())).addListener(configListener);
View Full Code Here


            connector.setRedirectPort(defaultRedirectPort);
        }

        ObservableBean httpListenerBean = (ObservableBean) ConfigSupport.getImpl(
                listener);
        httpListenerBean.addListener(configListener);

        return connector;
    }

    /**
 
View Full Code Here

        // Add Host to Engine
        engine.addChild(vs);

        ObservableBean virtualServerBean = (ObservableBean) ConfigSupport.getImpl(vsBean);
        virtualServerBean.addListener(configListener);

        return vs;
    }

View Full Code Here

    }

    private void addListenerToResources(){
        Resources resources = domain.getResources();
        ObservableBean bean = (ObservableBean) ConfigSupport.getImpl((ConfigBeanProxy)resources);
        bean.addListener(this);
    }

    private void addListenerToServer() {
        Server server = domain.getServerNamed(environment.getInstanceName());
        ObservableBean bean = (ObservableBean) ConfigSupport.getImpl((ConfigBeanProxy)server);
View Full Code Here

    }

    private void addListenerToServer() {
        Server server = domain.getServerNamed(environment.getInstanceName());
        ObservableBean bean = (ObservableBean) ConfigSupport.getImpl((ConfigBeanProxy)server);
        bean.addListener(this);
    }

    private void bindConnectorDescriptors() {
        for(String rarName : ConnectorConstants.systemRarNames){
            bindConnectorDescriptorProxies(rarName);
View Full Code Here

        ObservableBean bean = null;

        //add listener to all types of Resource
        if(instance instanceof Resource){
            bean = (ObservableBean) ConfigSupport.getImpl((ConfigBeanProxy)instance);
            bean.addListener(this);
        } else if(instance instanceof ResourceRef) {
            bean = (ObservableBean) ConfigSupport.getImpl((ConfigBeanProxy)instance);
            bean.addListener(this);
        }
    }
View Full Code Here

        if(instance instanceof Resource){
            bean = (ObservableBean) ConfigSupport.getImpl((ConfigBeanProxy)instance);
            bean.addListener(this);
        } else if(instance instanceof ResourceRef) {
            bean = (ObservableBean) ConfigSupport.getImpl((ConfigBeanProxy)instance);
            bean.addListener(this);
        }
    }


    /**
 
View Full Code Here

        ObservableBean bean = null;
        if(_logger.isLoggable(Level.FINEST)){
            debug("adding listener : " + instance);
        }
        bean = (ObservableBean) ConfigSupport.getImpl((ConfigBeanProxy)instance);
        bean.addListener(this);
    }

    /**
     * Remove listener from all resources - JDBC Connection Pools/JDBC Resources/
     * Connector Connection Pools/ Connector Resources.
View Full Code Here

        configListener = addAndGetWebConfigListener();

        ObservableBean bean = (ObservableBean) ConfigSupport.getImpl(
                serverConfig.getHttpService());
        bean.addListener(configListener);

        bean = (ObservableBean) ConfigSupport.getImpl(
                serverConfig.getNetworkConfig().getNetworkListeners());
        bean.addListener(configListener);
View Full Code Here

                serverConfig.getHttpService());
        bean.addListener(configListener);

        bean = (ObservableBean) ConfigSupport.getImpl(
                serverConfig.getNetworkConfig().getNetworkListeners());
        bean.addListener(configListener);

        if (serverConfig.getAvailabilityService() != null) {
            bean = (ObservableBean) ConfigSupport.getImpl(
                    serverConfig.getAvailabilityService());
            bean.addListener(configListener);
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.