org.springframework.richclient.dialog
Class DefaultMessageAreaPane

java.lang.Object
  extended by org.springframework.richclient.application.support.ApplicationServicesAccessor
      extended by org.springframework.richclient.factory.AbstractControlFactory
          extended by org.springframework.richclient.dialog.DefaultMessageAreaPane
All Implemented Interfaces:
PropertyChangeListener, EventListener, PropertyChangePublisher, Messagable, MessagePane, ControlFactory

public class DefaultMessageAreaPane
extends AbstractControlFactory
implements MessagePane, PropertyChangeListener

Author:
Keith Donald, Oliver Hutchison

Field Summary
static int DEFAULT_LINES_TO_DISPLAY
           
 
Fields inherited from class org.springframework.richclient.application.support.ApplicationServicesAccessor
logger
 
Fields inherited from interface org.springframework.richclient.dialog.Messagable
MESSAGE_PROPERTY
 
Constructor Summary
DefaultMessageAreaPane()
           
DefaultMessageAreaPane(int linesToDisplay)
           
DefaultMessageAreaPane(int linesToDisplay, Messagable delegateFor)
           
DefaultMessageAreaPane(Messagable delegateFor)
           
 
Method Summary
 void addPropertyChangeListener(PropertyChangeListener listener)
          Register a listener to all properties of this publisher.
 void addPropertyChangeListener(String propertyName, PropertyChangeListener listener)
          Register a listener to a specific property.
 void clearMessage()
           
protected  JComponent createControl()
          Subclasses must override this method to create a new instance of the control that this factory produces.
 Message getMessage()
           
 boolean isMessageShowing()
          Is this pane currently showing a message?
 void propertyChange(PropertyChangeEvent evt)
           
 void removePropertyChangeListener(PropertyChangeListener listener)
          Remove the listener from all properties of this publisher.
 void removePropertyChangeListener(String propertyName, PropertyChangeListener listener)
          Remove the listener from a specific property.
 void setDefaultIcon(Icon defaultIcon)
           
 void setMessage(Message message)
          Set the message.
 
Methods inherited from class org.springframework.richclient.factory.AbstractControlFactory
createControlIfNecessary, getControl, isControlCreated, isSingleton, setSingleton
 
Methods inherited from class org.springframework.richclient.application.support.ApplicationServicesAccessor
getActiveWindow, getApplication, getApplicationContext, getApplicationName, getApplicationServices, getCommandConfigurer, getComponentFactory, getConversionService, getIconSource, getImageSource, getMessage, getMessage, getMessage, getMessage, getMessages, getMessageSource, getObjectConfigurer, getService
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.springframework.richclient.factory.ControlFactory
getControl
 

Field Detail

DEFAULT_LINES_TO_DISPLAY

public static final int DEFAULT_LINES_TO_DISPLAY
See Also:
Constant Field Values
Constructor Detail

DefaultMessageAreaPane

public DefaultMessageAreaPane()

DefaultMessageAreaPane

public DefaultMessageAreaPane(int linesToDisplay)

DefaultMessageAreaPane

public DefaultMessageAreaPane(Messagable delegateFor)

DefaultMessageAreaPane

public DefaultMessageAreaPane(int linesToDisplay,
                              Messagable delegateFor)
Method Detail

setDefaultIcon

public void setDefaultIcon(Icon defaultIcon)

createControl

protected JComponent createControl()
Description copied from class: AbstractControlFactory
Subclasses must override this method to create a new instance of the control that this factory produces.

Specified by:
createControl in class AbstractControlFactory
Returns:
The newly created control, never null.

getMessage

public Message getMessage()
Specified by:
getMessage in interface MessagePane

setMessage

public void setMessage(Message message)
Description copied from interface: Messagable
Set the message.

Specified by:
setMessage in interface Messagable

clearMessage

public void clearMessage()

isMessageShowing

public boolean isMessageShowing()
Description copied from interface: MessagePane
Is this pane currently showing a message?

Specified by:
isMessageShowing in interface MessagePane
Returns:
true or false

addPropertyChangeListener

public void addPropertyChangeListener(PropertyChangeListener listener)
Description copied from interface: PropertyChangePublisher
Register a listener to all properties of this publisher.

Specified by:
addPropertyChangeListener in interface PropertyChangePublisher
Parameters:
listener - the PropertyChangeListener to register.

addPropertyChangeListener

public void addPropertyChangeListener(String propertyName,
                                      PropertyChangeListener listener)
Description copied from interface: PropertyChangePublisher
Register a listener to a specific property.

Specified by:
addPropertyChangeListener in interface PropertyChangePublisher
Parameters:
propertyName - the property to monitor.
listener - the PropertyChangeListener to register.

removePropertyChangeListener

public void removePropertyChangeListener(PropertyChangeListener listener)
Description copied from interface: PropertyChangePublisher
Remove the listener from all properties of this publisher.

Specified by:
removePropertyChangeListener in interface PropertyChangePublisher
Parameters:
listener - the PropertyChangeListener to remove.

removePropertyChangeListener

public void removePropertyChangeListener(String propertyName,
                                         PropertyChangeListener listener)
Description copied from interface: PropertyChangePublisher
Remove the listener from a specific property.

Specified by:
removePropertyChangeListener in interface PropertyChangePublisher
Parameters:
propertyName - the property that was being monitored.
listener - the PropertyChangeListener to remove.

propertyChange

public void propertyChange(PropertyChangeEvent evt)
Specified by:
propertyChange in interface PropertyChangeListener


Copyright © 2004-2008 The Spring Framework. All Rights Reserved.