com.mockobjects.beans

Class MockPropertyChangeListener

Implemented Interfaces:
PropertyChangeListener, Verifiable

public class MockPropertyChangeListener
extends MockObject
implements PropertyChangeListener

Mock object for a PropertyChangeListener. This mock object can be used in verifying the event propagation mechanism of beans. You can set the information you expect from a PropertyChangeEvent as well as the number of events. If you expect more than one event, only the actual values of the last event are stored.
Author:
Ringo De Smet - MediaGeniX NV

Constructor Summary

MockPropertyChangeListener()
MockPropertyChangeListener(String name)

Method Summary

void
propertyChange(PropertyChangeEvent event)
void
setExpectedEventCount(int expectedEventCount)
void
setExpectedNewValue(Object expectedNewValue)
void
setExpectedOldValue(Object expectedOldValue)
void
setExpectedPropertyName(String expectedPropertyName)

Methods inherited from class com.mockobjects.MockObject

notImplemented, notYetImplemented, verify

Constructor Details

MockPropertyChangeListener

public MockPropertyChangeListener()

MockPropertyChangeListener

public MockPropertyChangeListener(String name)

Method Details

propertyChange

public void propertyChange(PropertyChangeEvent event)

setExpectedEventCount

public void setExpectedEventCount(int expectedEventCount)

setExpectedNewValue

public void setExpectedNewValue(Object expectedNewValue)

setExpectedOldValue

public void setExpectedOldValue(Object expectedOldValue)

setExpectedPropertyName

public void setExpectedPropertyName(String expectedPropertyName)

Copyright © 2002 Mock Objects. All Rights Reserved.