Package org.apache.commons.configuration.event

Examples of org.apache.commons.configuration.event.EventSource


        }
    }

    public void addChangeListener( RegistryListener listener )
    {
        EventSource configuration = (EventSource) this.configuration;

        configuration.addConfigurationListener( new ConfigurationListenerDelegate( listener, this ) );
    }
View Full Code Here


        }
    }

    public void addChangeListener( RegistryListener listener )
    {
        EventSource eventSource = EventSource.class.cast( this.configuration );

        eventSource.addConfigurationListener( new ConfigurationListenerDelegate( listener, this ) );
    }
View Full Code Here

    }

    @Override
    public boolean removeChangeListener( RegistryListener listener )
    {
        EventSource eventSource = EventSource.class.cast( this.configuration );

        boolean removed =
            eventSource.removeConfigurationListener( new ConfigurationListenerDelegate( listener, this ) );

        return removed;
    }
View Full Code Here

     *
     * @param obj the object to initialize
     */
    private void registerEventListeners(T obj)
    {
        EventSource evSrc = ConfigurationUtils.asEventSource(obj, true);
        for (EventListenerRegistrationData<?> regData : eventListeners
                .getRegistrations())
        {
            registerListener(evSrc, regData);
        }
View Full Code Here

     *
     * @param obj the affected result object
     */
    private void removeEventListeners(T obj)
    {
        EventSource evSrc = ConfigurationUtils.asEventSource(obj, true);
        for (EventListenerRegistrationData<?> regData : eventListeners
                .getRegistrations())
        {
            removeListener(evSrc, regData);
        }
View Full Code Here

TOP

Related Classes of org.apache.commons.configuration.event.EventSource

Copyright © 2018 www.massapicom. 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.