Package eu.bandm.tools.message
Class MessageStore<M extends Message>
java.lang.Object
eu.bandm.tools.message.MessageStore_<M>
eu.bandm.tools.message.MessageStore<M>
- All Implemented Interfaces:
MessageReceiver<M>
Storage for a sequence of
All messages received are added to an internal sequential storage in the order of arrival. Additionally the nesting level of
Message
s with dynamic sorting, graphic
interfaces and propagation facilities. All messages received are added to an internal sequential storage in the order of arrival. Additionally the nesting level of
Message.Kind.logStart
and
Message.Kind.logEnd
messages is stored, which can be
rendered by a GUI.-
Nested Class Summary
Modifier and TypeClassDescriptionclass
standard specialisation ofAbstractListModel
.class
standard specialisation ofAbstractTableModel
. -
Field Summary
Modifier and TypeFieldDescriptionprotected int
Internal state for storing the nesting ofMessage.Kind.logStart
andMessage.Kind.logEnd
messages.Fields inherited from class eu.bandm.tools.message.MessageStore_
indents, listModel, messages, tableModel
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
Resets nesting level to 0.void
Adds the received message to the internal store and notifies all GUI objects.Methods inherited from class eu.bandm.tools.message.MessageStore_
clear, drainAndClear, drainTo, getListModel, getMessages, getSize, getTableModel, notifyGuiAdd, notifyGuiChanged_ALL, setListModel, setTableModel
-
Field Details
-
nestingLevel
protected int nestingLevelInternal state for storing the nesting ofMessage.Kind.logStart
andMessage.Kind.logEnd
messages. Is always >=0, also in case of inconsistent nesting of incomming messages.
-
-
Constructor Details
-
MessageStore
public MessageStore()
-
-
Method Details
-
clearNestingLevel
public void clearNestingLevel()Resets nesting level to 0. -
receive
Adds the received message to the internal store and notifies all GUI objects.
Counts the nesting level ofMessage.Kind.logStart
andMessage.Kind.logEnd
messages. Never goes below zero(0).- Specified by:
receive
in interfaceMessageReceiver<M extends Message>
- Specified by:
receive
in classMessageStore_<M extends Message>
-