Examples of removeVetoableChangeListener()


Examples of java.beans.beancontext.BeanContextChildSupport.removeVetoableChangeListener()

        support.removePropertyChangeListener(propName, l1);
    }

    public void testRemoveVetoableChangeListener_NullParam() {
        BeanContextChildSupport support = new MockBeanContextChildSupport();
        support.removeVetoableChangeListener("property name", null);
    }

    public void testRemoveVetoableChangeListener() throws PropertyVetoException {
        BeanContextChildSupport support = new MockBeanContextChildSupport();
        MockVetoableChangeListener l1 = new MockVetoableChangeListener();
View Full Code Here

Examples of java.beans.beancontext.BeanContextChildSupport.removeVetoableChangeListener()

        assertEquals(propName, l2.lastEvent.getPropertyName());
        assertSame(oldValue, l2.lastEvent.getOldValue());
        assertSame(newValue, l2.lastEvent.getNewValue());
        assertSame(support, l2.lastEvent.getSource());

        support.removeVetoableChangeListener(propName, l1);
        l1.clearLastEvent();
        l2.clearLastEvent();
        support.fireVetoableChange(propName, oldValue, newValue);
        assertNull(l1.lastEvent);
        assertEquals(l2.lastEvent.getPropertyName(), propName);
View Full Code Here

Examples of java.beans.beancontext.BeanContextChildSupport.removeVetoableChangeListener()

        assertEquals(l2.lastEvent.getPropertyName(), propName);
        assertSame(l2.lastEvent.getOldValue(), oldValue);
        assertSame(l2.lastEvent.getNewValue(), newValue);
        assertSame(l2.lastEvent.getSource(), support);

        support.removeVetoableChangeListener(propName, l2);
        l1.clearLastEvent();
        l2.clearLastEvent();
        support.fireVetoableChange(propName, oldValue, newValue);
        assertNull(l1.lastEvent);
        assertNull(l2.lastEvent);
View Full Code Here

Examples of java.beans.beancontext.BeanContextChildSupport.removeVetoableChangeListener()

        support.fireVetoableChange(propName, oldValue, newValue);
        assertNull(l1.lastEvent);
        assertNull(l2.lastEvent);

        // remove not-registered listener
        support.removeVetoableChangeListener(propName, l1);
    }

    public void testServiceAvailable() {
        // guess the impl is empty
        BeanContextChildSupport support = new MockBeanContextChildSupport();
View Full Code Here

Examples of java.beans.beancontext.BeanContextChildSupport.removeVetoableChangeListener()

        support.removePropertyChangeListener(propName, l1);
    }

    public void testRemoveVetoableChangeListener_NullParam() {
        BeanContextChildSupport support = new MockBeanContextChildSupport();
        support.removeVetoableChangeListener("property name", null);
    }

    public void testRemoveVetoableChangeListener() throws PropertyVetoException {
        BeanContextChildSupport support = new MockBeanContextChildSupport();
        MockVetoableChangeListener l1 = new MockVetoableChangeListener();
View Full Code Here

Examples of java.beans.beancontext.BeanContextChildSupport.removeVetoableChangeListener()

        assertEquals(propName, l2.lastEvent.getPropertyName());
        assertSame(oldValue, l2.lastEvent.getOldValue());
        assertSame(newValue, l2.lastEvent.getNewValue());
        assertSame(support, l2.lastEvent.getSource());

        support.removeVetoableChangeListener(propName, l1);
        l1.clearLastEvent();
        l2.clearLastEvent();
        support.fireVetoableChange(propName, oldValue, newValue);
        assertNull(l1.lastEvent);
        assertEquals(l2.lastEvent.getPropertyName(), propName);
View Full Code Here

Examples of java.beans.beancontext.BeanContextChildSupport.removeVetoableChangeListener()

        assertEquals(l2.lastEvent.getPropertyName(), propName);
        assertSame(l2.lastEvent.getOldValue(), oldValue);
        assertSame(l2.lastEvent.getNewValue(), newValue);
        assertSame(l2.lastEvent.getSource(), support);

        support.removeVetoableChangeListener(propName, l2);
        l1.clearLastEvent();
        l2.clearLastEvent();
        support.fireVetoableChange(propName, oldValue, newValue);
        assertNull(l1.lastEvent);
        assertNull(l2.lastEvent);
View Full Code Here

Examples of java.beans.beancontext.BeanContextChildSupport.removeVetoableChangeListener()

        support.fireVetoableChange(propName, oldValue, newValue);
        assertNull(l1.lastEvent);
        assertNull(l2.lastEvent);

        // remove not-registered listener
        support.removeVetoableChangeListener(propName, l1);
    }

    public void testServiceAvailable() {
        // guess the impl is empty
        BeanContextChildSupport support = new MockBeanContextChildSupport();
View Full Code Here

Examples of javax.swing.JButton.removeVetoableChangeListener()

  {
    JComponent c = new JButton("ABC");
    harness.check(c.getVetoableChangeListeners().length, 0);
    c.addVetoableChangeListener(this);
    harness.check(c.getVetoableChangeListeners().length, 1);
    c.removeVetoableChangeListener(this);
    harness.check(c.getVetoableChangeListeners().length, 0);
    c.removeVetoableChangeListener(this);
    harness.check(c.getVetoableChangeListeners().length, 0);   
    c.removeVetoableChangeListener(null);
    harness.check(c.getVetoableChangeListeners().length, 0);   
View Full Code Here

Examples of javax.swing.JButton.removeVetoableChangeListener()

    harness.check(c.getVetoableChangeListeners().length, 0);
    c.addVetoableChangeListener(this);
    harness.check(c.getVetoableChangeListeners().length, 1);
    c.removeVetoableChangeListener(this);
    harness.check(c.getVetoableChangeListeners().length, 0);
    c.removeVetoableChangeListener(this);
    harness.check(c.getVetoableChangeListeners().length, 0);   
    c.removeVetoableChangeListener(null);
    harness.check(c.getVetoableChangeListeners().length, 0);   
  }
}
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.