Cool documentation

com.sap.tc.col.client.generic.api
Interface IMessageList


public interface IMessageList

Contains a list of IMessages.

The content of the list is created by the framework only, therefore there is no API to crewate or add messages to this list. If messages have been processed by a client it can remove one or all messages from the list.

Several message lists can be combined to a cumulated message list. This is for example used by the service facade to provide an "All Messages" list. Removing messages from a cumulating list removes them from all cumulated list and vice versa.


Method Summary
 void clear()
          Removes all messages from this message list.
 IMessage getMessage(int index)
          Returns the message at index index where 0 <= index <= size().
 boolean isEmpty()
          Returns true if there are no messages in this list.
 boolean removeMessage(IMessage message)
          Removes the given message from this list.
 int size()
          Returns the number of messages in this list
 

Method Detail

clear

public void clear()
Removes all messages from this message list.

If an owner of an IMessageList doesn't allow clearing the list, then the owner by convention has to document this constraint for its getMessages() method. clear() then might throw an UnsupportedOperationException.


getMessage

public IMessage getMessage(int index)
Returns the message at index index where 0 <= index <= size().

removeMessage

public boolean removeMessage(IMessage message)
Removes the given message from this list.

If this list is a cumulated list, then the message is removed from any dependant lists, too. If this list is cumulated in another list, the message is removed from that list as well.


isEmpty

public boolean isEmpty()
Returns true if there are no messages in this list.

size

public int size()
Returns the number of messages in this list

Cool documentation

Copyright © 2002 SAP AG. Automatically generated Thu Mar 3 2005, 21:55