Package org.apache.log4j.chainsaw
Class LogPanel
- java.lang.Object
-
- java.awt.Component
-
- java.awt.Container
-
- javax.swing.JComponent
-
- javax.swing.JPanel
-
- org.apache.log4j.chainsaw.DockablePanel
-
- org.apache.log4j.chainsaw.LogPanel
-
- All Implemented Interfaces:
java.awt.image.ImageObserver
,java.awt.MenuContainer
,java.io.Serializable
,java.util.EventListener
,javax.accessibility.Accessible
,EventBatchListener
,Profileable
,SettingsListener
public class LogPanel extends DockablePanel implements EventBatchListener, Profileable
A LogPanel provides a view to a collection of LoggingEvents.
As events are received, the keywords in the 'tab identifier' application preference are replaced with the values from the received event. The main application uses this expression to route received LoggingEvents to individual LogPanels which match each event's resolved expression.
The LogPanel's capabilities can be broken up into four areas:
- toolbar - provides 'find' and 'refine focus' features
- logger tree - displays a tree of the logger hierarchy, which can be used to filter the display
- table - displays the events which pass the filtering rules
- detail panel - displays information about the currently selected event
- display selected LoggingEvent row number and total LoggingEvent count
- pause or unpause reception of LoggingEvents
- configure, load and save column settings (displayed columns, order, width)
- configure, load and save color rules filter displayed LoggingEvents based on the logger tree settings
- filter displayed LoggingEvents based on a 'refine focus' expression (evaluates only those LoggingEvents which pass the logger tree filter
- colorize LoggingEvents based on expressions
- hide, show and configure the detail pane and tooltip
- configure the formatting of the logger, level and timestamp fields
- dock or undock
- table displays first line of exception, but when cell is clicked, a popup opens to display the full stack trace
- find
- scroll to bottom
- sort
- provide a context menu which can be used to build color or display expressions
- hide or show the logger tree
- toggle the container storing the LoggingEvents to use either a CyclicBuffer (defaults to max size of 5000, but configurable through CHAINSAW_CAPACITY system property) or ArrayList (no max size)
- use the mouse context menu to 'best-fit' columns, define display expression filters based on mouse location and access other capabilities
- See Also:
ColorPanel
,ExpressionRule
,LoggingEventFieldResolver
, Serialized Form
-
-
Nested Class Summary
Nested Classes Modifier and Type Class Description (package private) class
LogPanel.AbstractEventMatchThumbnail
(package private) class
LogPanel.AutoFilterComboBox
private class
LogPanel.ChainsawTableColumnModelListener
private class
LogPanel.ColorizedEventAndSearchMatchThumbnail
private class
LogPanel.DelayedTextDocumentListener
This class receives notification when the Refine focus or find field is updated, where a background thread periodically wakes up and checks if they have stopped typing yet.private class
LogPanel.DetailPaneUpdater
Thread that periodically checks if the selected row has changed, and if it was, updates the Detail Panel with the detailed Logging informationprivate class
LogPanel.EventTimeDeltaMatchThumbnail
private class
LogPanel.MarkerCellEditor
private class
LogPanel.TableColumnDetailMouseListener
Update active tooltipprivate class
LogPanel.TableMarkerListener
private class
LogPanel.ThrowableDisplayMouseAdapter
(package private) class
LogPanel.ThumbnailLoggingEventWrapper
(package private) class
LogPanel.ToggleToolTips
-
Nested classes/interfaces inherited from class javax.swing.JPanel
javax.swing.JPanel.AccessibleJPanel
-
Nested classes/interfaces inherited from class javax.swing.JComponent
javax.swing.JComponent.AccessibleJComponent
-
-
Field Summary
-
Fields inherited from class javax.swing.JComponent
listenerList, TOOL_TIP_TEXT_KEY, ui, UNDEFINED_CONDITION, WHEN_ANCESTOR_OF_FOCUSED_COMPONENT, WHEN_FOCUSED, WHEN_IN_FOCUSED_WINDOW
-
-
Constructor Summary
Constructors Constructor Description LogPanel(ChainsawStatusBar statusBar, java.lang.String identifier, int cyclicBufferSize, java.util.Map<java.lang.String,RuleColorizer> allColorizers, ApplicationPreferenceModel applicationPreferenceModel)
Creates a new LogPanel object.
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description (package private) void
addEventCountListener(EventCountListener l)
Add an eventCountListener(package private) void
addPreferencePropertyChangeListener(java.beans.PropertyChangeListener listener)
Add a preference propertyChangeListenerprivate void
buildCombo(LogPanel.AutoFilterComboBox combo, boolean isFiltering, LogPanel.AutoFilterComboBox.AutoFilterComboBoxModel otherModel)
private com.thoughtworks.xstream.XStream
buildXStreamForLogPanelPreference()
static void
centerAndSetVisible(java.awt.Window window)
void
clearAllMarkers()
(package private) void
clearEvents()
Remove all eventsprivate void
clearModel()
Reset the LoggingEvent container, detail panel and status barprivate javax.swing.JToolBar
createDockwindowToolbar()
Return a toolbar used by the undocked LogPanel's frameprivate void
dock()
Docks this DockablePanel by hiding the JFrame and placing the Panel back inside the LogUI window.void
findNext()
Finds the next row matching the current find rule, and ensures it is made visiblevoid
findNextColorizedEvent()
void
findNextMarker()
void
findPrevious()
Finds the previous row matching the current find rule, and ensures it is made visiblevoid
findPreviousColorizedEvent()
void
findPreviousMarker()
private java.lang.String
getDetailPaneConversionPattern()
Accessor(package private) java.util.List
getEvents()
Return all events(package private) java.util.List
getFilteredEvents()
Return the events that are visible with the current filter appliedprivate javax.swing.Action
getFindNextAction()
private javax.swing.Action
getFindPreviousAction()
java.lang.String
getFindText()
(package private) java.lang.String
getIdentifier()
Accessorjava.lang.String
getInterestedIdentifier()
Accessor(package private) java.util.List<LoggingEventWrapper>
getMatchingEvents(org.apache.log4j.rule.Rule rule)
private int
getMaxColumnWidth(int index)
Iterate over all values in the column and return the longest widthjava.lang.String
getNamespace()
Accessorjava.lang.String
getRefineFocusText()
private java.lang.String
getToolTipTextForEvent(LoggingEventWrapper loggingEventWrapper)
private java.lang.String
getValueOf(int row, int column)
private void
hideDetailPane()
Hide the detail pane, holding the current divider location for later useprivate void
hideLogTreePanel()
Hide the log tree pane, holding the current divider location for later useprivate void
hideSearchResults()
(package private) boolean
isCyclic()
Accessor(package private) boolean
isDetailVisible()
Accessor(package private) boolean
isLogTreeVisible()
Accessor(package private) boolean
isPaused()
Accessorboolean
isScrollToBottom()
Accessor(package private) boolean
isSearchResultsVisible()
void
layoutComponents()
private void
loadDefaultColumnSettings(LoadSettingsEvent event)
Load default column settings if no settings exist for this identifiervoid
loadSettings(LoadSettingsEvent event)
Load settings from the panel preference modelvoid
receiveEventBatch(java.lang.String ident, java.util.List<org.apache.log4j.spi.LoggingEvent> events)
Process events associated with the identifier.void
saveSettings(SaveSettingsEvent event)
Save preferences to the panel preference modelprivate void
scrollToBottom()
void
scrollToTop()
private void
setDetailPaneConversionPattern(java.lang.String conversionPattern)
Update the detail pane layout textvoid
setFindText(java.lang.String findText)
(package private) void
setPaused(boolean paused)
Modifies the Paused property and notifies the listenersvoid
setRefineFocusText(java.lang.String refineFocusText)
(package private) int
setSelectedEvent(int eventNumber)
Change the selected event on the log panel.(package private) void
showColorPreferences()
Display the color rule frameprivate void
showDetailPane()
Display the detail pane, using the last known divider locationprivate void
showLogTreePanel()
Display the log tree pane, using the last known divider location(package private) void
showPreferences()
Display the panel preferences frameprivate void
showSearchResults()
(package private) void
toggleCyclic()
Toggle the LoggingEvent container from either managing a cyclic buffer of events or an ArrayList of events(package private) void
toggleDetailVisible()
Toggle panel preference for detail visibility on or off(package private) void
toggleLogTreeVisible()
Toggle panel preference for logger tree visibility on or offvoid
toggleMarker()
void
toggleScrollToBottom()
Mutator(package private) void
undock()
Undocks this DockablePanel by removing the panel from the LogUI window and placing it inside it's own JFrame.void
updateFindRule(java.lang.String ruleText)
private void
updateOtherModels(org.apache.log4j.spi.LoggingEvent event)
ensures the Entry map of all the unque logger names etc, that is used for the Filter panel is updated with any new information from the eventprotected void
updateStatusBar()
Update the status bar with current selected row and row count-
Methods inherited from class org.apache.log4j.chainsaw.DockablePanel
getPreferredSize, isDocked, setDocked
-
Methods inherited from class javax.swing.JPanel
getAccessibleContext, getUI, getUIClassID, paramString, setUI, updateUI
-
Methods inherited from class javax.swing.JComponent
addAncestorListener, addNotify, addVetoableChangeListener, computeVisibleRect, contains, createToolTip, disable, enable, firePropertyChange, firePropertyChange, firePropertyChange, fireVetoableChange, getActionForKeyStroke, getActionMap, getAlignmentX, getAlignmentY, getAncestorListeners, getAutoscrolls, getBaseline, getBaselineResizeBehavior, getBorder, getBounds, getClientProperty, getComponentGraphics, getComponentPopupMenu, getConditionForKeyStroke, getDebugGraphicsOptions, getDefaultLocale, getFontMetrics, getGraphics, getHeight, getInheritsPopupMenu, getInputMap, getInputMap, getInputVerifier, getInsets, getInsets, getListeners, getLocation, getMaximumSize, getMinimumSize, getNextFocusableComponent, getPopupLocation, getRegisteredKeyStrokes, getRootPane, getSize, getToolTipLocation, getToolTipText, getToolTipText, getTopLevelAncestor, getTransferHandler, getVerifyInputWhenFocusTarget, getVetoableChangeListeners, getVisibleRect, getWidth, getX, getY, grabFocus, hide, isDoubleBuffered, isLightweightComponent, isManagingFocus, isOpaque, isOptimizedDrawingEnabled, isPaintingForPrint, isPaintingOrigin, isPaintingTile, isRequestFocusEnabled, isValidateRoot, paint, paintBorder, paintChildren, paintComponent, paintImmediately, paintImmediately, print, printAll, printBorder, printChildren, printComponent, processComponentKeyEvent, processKeyBinding, processKeyEvent, processMouseEvent, processMouseMotionEvent, putClientProperty, registerKeyboardAction, registerKeyboardAction, removeAncestorListener, removeNotify, removeVetoableChangeListener, repaint, repaint, requestDefaultFocus, requestFocus, requestFocus, requestFocusInWindow, requestFocusInWindow, resetKeyboardActions, reshape, revalidate, scrollRectToVisible, setActionMap, setAlignmentX, setAlignmentY, setAutoscrolls, setBackground, setBorder, setComponentPopupMenu, setDebugGraphicsOptions, setDefaultLocale, setDoubleBuffered, setEnabled, setFocusTraversalKeys, setFont, setForeground, setInheritsPopupMenu, setInputMap, setInputVerifier, setMaximumSize, setMinimumSize, setNextFocusableComponent, setOpaque, setPreferredSize, setRequestFocusEnabled, setToolTipText, setTransferHandler, setUI, setVerifyInputWhenFocusTarget, setVisible, unregisterKeyboardAction, update
-
Methods inherited from class java.awt.Container
add, add, add, add, add, addContainerListener, addImpl, addPropertyChangeListener, addPropertyChangeListener, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, doLayout, findComponentAt, findComponentAt, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getComponentZOrder, getContainerListeners, getFocusTraversalKeys, getFocusTraversalPolicy, getLayout, getMousePosition, insets, invalidate, isAncestorOf, isFocusCycleRoot, isFocusCycleRoot, isFocusTraversalPolicyProvider, isFocusTraversalPolicySet, layout, list, list, locate, minimumSize, paintComponents, preferredSize, printComponents, processContainerEvent, processEvent, remove, remove, removeAll, removeContainerListener, setComponentZOrder, setFocusCycleRoot, setFocusTraversalPolicy, setFocusTraversalPolicyProvider, setLayout, transferFocusDownCycle, validate, validateTree
-
Methods inherited from class java.awt.Component
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addMouseWheelListener, bounds, checkImage, checkImage, coalesceEvents, contains, createImage, createImage, createVolatileImage, createVolatileImage, disableEvents, dispatchEvent, enable, enableEvents, enableInputMethods, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, getBackground, getBounds, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusCycleRootAncestor, getFocusListeners, getFocusTraversalKeysEnabled, getFont, getForeground, getGraphicsConfiguration, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputContext, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getLocale, getLocation, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, getMousePosition, getMouseWheelListeners, getName, getParent, getPropertyChangeListeners, getPropertyChangeListeners, getSize, getToolkit, getTreeLock, gotFocus, handleEvent, hasFocus, imageUpdate, inside, isBackgroundSet, isCursorSet, isDisplayable, isEnabled, isFocusable, isFocusOwner, isFocusTraversable, isFontSet, isForegroundSet, isLightweight, isMaximumSizeSet, isMinimumSizeSet, isPreferredSizeSet, isShowing, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, postEvent, prepareImage, prepareImage, processComponentEvent, processFocusEvent, processHierarchyBoundsEvent, processHierarchyEvent, processInputMethodEvent, processMouseWheelEvent, remove, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, requestFocus, requestFocus, requestFocusInWindow, resize, resize, setBounds, setBounds, setComponentOrientation, setCursor, setDropTarget, setFocusable, setFocusTraversalKeysEnabled, setIgnoreRepaint, setLocale, setLocation, setLocation, setMixingCutoutShape, setName, setSize, setSize, show, show, size, toString, transferFocus, transferFocusBackward, transferFocusUpCycle
-
-
-
-
Field Detail
-
TIMESTAMP_DATE_FORMAT
private static final java.text.DateFormat TIMESTAMP_DATE_FORMAT
-
DEFAULT_DETAIL_SPLIT_LOCATION
private static final double DEFAULT_DETAIL_SPLIT_LOCATION
- See Also:
- Constant Field Values
-
DEFAULT_LOG_TREE_SPLIT_LOCATION
private static final double DEFAULT_LOG_TREE_SPLIT_LOCATION
- See Also:
- Constant Field Values
-
identifier
private final java.lang.String identifier
-
statusBar
private final ChainsawStatusBar statusBar
-
logPanelPreferencesFrame
private final javax.swing.JFrame logPanelPreferencesFrame
-
colorPanel
private ColorPanel colorPanel
-
colorFrame
private final javax.swing.JFrame colorFrame
-
undockedFrame
private final javax.swing.JFrame undockedFrame
-
externalPanel
private final DockablePanel externalPanel
-
dockingAction
private final javax.swing.Action dockingAction
-
undockedToolbar
private final javax.swing.JToolBar undockedToolbar
-
table
private final JSortTable table
-
renderer
private final TableColorizingRenderer renderer
-
tableModel
private final EventContainer tableModel
-
detail
private final javax.swing.JEditorPane detail
-
lowerPanel
private final javax.swing.JSplitPane lowerPanel
-
detailPaneUpdater
private final LogPanel.DetailPaneUpdater detailPaneUpdater
-
detailPanel
private final javax.swing.JPanel detailPanel
-
nameTreeAndMainPanelSplit
private final javax.swing.JSplitPane nameTreeAndMainPanelSplit
-
logTreePanel
private final LoggerNameTreePanel logTreePanel
-
preferenceModel
private final LogPanelPreferenceModel preferenceModel
-
applicationPreferenceModel
private ApplicationPreferenceModel applicationPreferenceModel
-
logPanelPreferencesPanel
private final LogPanelPreferencePanel logPanelPreferencesPanel
-
filterModel
private final FilterModel filterModel
-
colorizer
private final RuleColorizer colorizer
-
tableRuleMediator
private final RuleMediator tableRuleMediator
-
searchRuleMediator
private final RuleMediator searchRuleMediator
-
detailLayout
private final EventDetailLayout detailLayout
-
lastLogTreePanelSplitLocation
private double lastLogTreePanelSplitLocation
-
currentPoint
private java.awt.Point currentPoint
-
currentTable
private javax.swing.JTable currentTable
-
paused
private boolean paused
-
findRule
private org.apache.log4j.rule.Rule findRule
-
currentFindRuleText
private java.lang.String currentFindRuleText
-
findMarkerRule
private org.apache.log4j.rule.Rule findMarkerRule
-
dividerSize
private final int dividerSize
-
TABLE_COLUMN_ORDER
static final java.lang.String TABLE_COLUMN_ORDER
- See Also:
- Constant Field Values
-
TABLE_COLUMN_WIDTHS
static final java.lang.String TABLE_COLUMN_WIDTHS
- See Also:
- Constant Field Values
-
COLORS_EXTENSION
static final java.lang.String COLORS_EXTENSION
- See Also:
- Constant Field Values
-
LOG_PANEL_SERIALIZATION_VERSION_NUMBER
private static final int LOG_PANEL_SERIALIZATION_VERSION_NUMBER
- See Also:
- Constant Field Values
-
previousLastIndex
private int previousLastIndex
-
logger
private final org.apache.log4j.Logger logger
-
filterCombo
private LogPanel.AutoFilterComboBox filterCombo
-
findCombo
private LogPanel.AutoFilterComboBox findCombo
-
eventsPane
private javax.swing.JScrollPane eventsPane
-
currentSearchMatchCount
private int currentSearchMatchCount
-
clearTableExpressionRule
private org.apache.log4j.rule.Rule clearTableExpressionRule
-
lowerPanelDividerLocation
private int lowerPanelDividerLocation
-
searchModel
private EventContainer searchModel
-
searchTable
private final JSortTable searchTable
-
searchRenderer
private TableColorizingRenderer searchRenderer
-
mainToggleToolTips
private LogPanel.ToggleToolTips mainToggleToolTips
-
searchToggleToolTips
private LogPanel.ToggleToolTips searchToggleToolTips
-
detailPane
private javax.swing.JScrollPane detailPane
-
searchPane
private javax.swing.JScrollPane searchPane
-
markerCellEditor
private javax.swing.table.TableCellEditor markerCellEditor
-
detailToolbar
private javax.swing.JToolBar detailToolbar
-
searchResultsDisplayed
private boolean searchResultsDisplayed
-
colorizedEventAndSearchMatchThumbnail
private LogPanel.ColorizedEventAndSearchMatchThumbnail colorizedEventAndSearchMatchThumbnail
-
eventTimeDeltaMatchThumbnail
private LogPanel.EventTimeDeltaMatchThumbnail eventTimeDeltaMatchThumbnail
-
isDetailPanelVisible
private boolean isDetailPanelVisible
-
-
Constructor Detail
-
LogPanel
public LogPanel(ChainsawStatusBar statusBar, java.lang.String identifier, int cyclicBufferSize, java.util.Map<java.lang.String,RuleColorizer> allColorizers, ApplicationPreferenceModel applicationPreferenceModel)
Creates a new LogPanel object. If a LogPanel with this identifier has been loaded previously, reload settings saved on last exit.- Parameters:
statusBar
- shared status bar, provided by main applicationidentifier
- used to load and save settings
-
-
Method Detail
-
getValueOf
private java.lang.String getValueOf(int row, int column)
-
getFindNextAction
private javax.swing.Action getFindNextAction()
-
getFindPreviousAction
private javax.swing.Action getFindPreviousAction()
-
buildCombo
private void buildCombo(LogPanel.AutoFilterComboBox combo, boolean isFiltering, LogPanel.AutoFilterComboBox.AutoFilterComboBoxModel otherModel)
-
isScrollToBottom
public boolean isScrollToBottom()
Accessor- Returns:
- scrollToBottom
-
setRefineFocusText
public void setRefineFocusText(java.lang.String refineFocusText)
-
getRefineFocusText
public java.lang.String getRefineFocusText()
-
toggleScrollToBottom
public void toggleScrollToBottom()
Mutator
-
scrollToBottom
private void scrollToBottom()
-
scrollToTop
public void scrollToTop()
-
getNamespace
public java.lang.String getNamespace()
Accessor- Specified by:
getNamespace
in interfaceProfileable
- Returns:
- namespace
- See Also:
Profileable
-
getInterestedIdentifier
public java.lang.String getInterestedIdentifier()
Accessor- Specified by:
getInterestedIdentifier
in interfaceEventBatchListener
- Returns:
- identifier
- See Also:
EventBatchListener
-
receiveEventBatch
public void receiveEventBatch(java.lang.String ident, java.util.List<org.apache.log4j.spi.LoggingEvent> events)
Process events associated with the identifier. Currently assumes it only receives events which share this LogPanel's identifier- Specified by:
receiveEventBatch
in interfaceEventBatchListener
- Parameters:
ident
- identifier shared by eventsevents
- list of LoggingEvent objects
-
loadSettings
public void loadSettings(LoadSettingsEvent event)
Load settings from the panel preference model- Specified by:
loadSettings
in interfaceSettingsListener
- Parameters:
event
-- See Also:
LogPanelPreferenceModel
-
saveSettings
public void saveSettings(SaveSettingsEvent event)
Save preferences to the panel preference model- Specified by:
saveSettings
in interfaceSettingsListener
- Parameters:
event
-- See Also:
LogPanelPreferenceModel
-
buildXStreamForLogPanelPreference
private com.thoughtworks.xstream.XStream buildXStreamForLogPanelPreference()
-
showPreferences
void showPreferences()
Display the panel preferences frame
-
centerAndSetVisible
public static void centerAndSetVisible(java.awt.Window window)
-
showColorPreferences
void showColorPreferences()
Display the color rule frame
-
toggleDetailVisible
void toggleDetailVisible()
Toggle panel preference for detail visibility on or off
-
isDetailVisible
boolean isDetailVisible()
Accessor- Returns:
- detail visibility flag
-
isSearchResultsVisible
boolean isSearchResultsVisible()
-
toggleLogTreeVisible
void toggleLogTreeVisible()
Toggle panel preference for logger tree visibility on or off
-
isLogTreeVisible
boolean isLogTreeVisible()
Accessor- Returns:
- logger tree visibility flag
-
getEvents
java.util.List getEvents()
Return all events- Returns:
- list of LoggingEvents
-
getFilteredEvents
java.util.List getFilteredEvents()
Return the events that are visible with the current filter applied- Returns:
- list of LoggingEvents
-
getMatchingEvents
java.util.List<LoggingEventWrapper> getMatchingEvents(org.apache.log4j.rule.Rule rule)
-
clearEvents
void clearEvents()
Remove all events
-
getIdentifier
java.lang.String getIdentifier()
Accessor- Returns:
- identifier
-
undock
void undock()
Undocks this DockablePanel by removing the panel from the LogUI window and placing it inside it's own JFrame.
-
addEventCountListener
void addEventCountListener(EventCountListener l)
Add an eventCountListener- Parameters:
l
-
-
isPaused
boolean isPaused()
Accessor- Returns:
- paused flag
-
setPaused
void setPaused(boolean paused)
Modifies the Paused property and notifies the listeners- Parameters:
paused
-
-
setSelectedEvent
int setSelectedEvent(int eventNumber)
Change the selected event on the log panel. Will cause scrollToBottom to be turned off.- Parameters:
eventNumber
-- Returns:
- row number or -1 if row with log4jid property with that number was not found
-
addPreferencePropertyChangeListener
void addPreferencePropertyChangeListener(java.beans.PropertyChangeListener listener)
Add a preference propertyChangeListener- Parameters:
listener
-
-
toggleCyclic
void toggleCyclic()
Toggle the LoggingEvent container from either managing a cyclic buffer of events or an ArrayList of events
-
isCyclic
boolean isCyclic()
Accessor- Returns:
- flag answering if LoggingEvent container is a cyclic buffer
-
updateFindRule
public void updateFindRule(java.lang.String ruleText)
-
hideSearchResults
private void hideSearchResults()
-
showSearchResults
private void showSearchResults()
-
showDetailPane
private void showDetailPane()
Display the detail pane, using the last known divider location
-
hideDetailPane
private void hideDetailPane()
Hide the detail pane, holding the current divider location for later use
-
showLogTreePanel
private void showLogTreePanel()
Display the log tree pane, using the last known divider location
-
hideLogTreePanel
private void hideLogTreePanel()
Hide the log tree pane, holding the current divider location for later use
-
createDockwindowToolbar
private javax.swing.JToolBar createDockwindowToolbar()
Return a toolbar used by the undocked LogPanel's frame- Returns:
- toolbar
-
updateStatusBar
protected void updateStatusBar()
Update the status bar with current selected row and row count
-
setDetailPaneConversionPattern
private void setDetailPaneConversionPattern(java.lang.String conversionPattern)
Update the detail pane layout text- Parameters:
conversionPattern
- layout text
-
getDetailPaneConversionPattern
private java.lang.String getDetailPaneConversionPattern()
Accessor- Returns:
- conversionPattern layout text
-
clearModel
private void clearModel()
Reset the LoggingEvent container, detail panel and status bar
-
findNextColorizedEvent
public void findNextColorizedEvent()
-
findPreviousColorizedEvent
public void findPreviousColorizedEvent()
-
findNext
public void findNext()
Finds the next row matching the current find rule, and ensures it is made visible
-
findPrevious
public void findPrevious()
Finds the previous row matching the current find rule, and ensures it is made visible
-
dock
private void dock()
Docks this DockablePanel by hiding the JFrame and placing the Panel back inside the LogUI window.
-
loadDefaultColumnSettings
private void loadDefaultColumnSettings(LoadSettingsEvent event)
Load default column settings if no settings exist for this identifier- Parameters:
event
-
-
getMaxColumnWidth
private int getMaxColumnWidth(int index)
Iterate over all values in the column and return the longest width- Parameters:
index
- column index- Returns:
- longest width - relies on FontMetrics.stringWidth for calculation
-
getToolTipTextForEvent
private java.lang.String getToolTipTextForEvent(LoggingEventWrapper loggingEventWrapper)
-
updateOtherModels
private void updateOtherModels(org.apache.log4j.spi.LoggingEvent event)
ensures the Entry map of all the unque logger names etc, that is used for the Filter panel is updated with any new information from the event- Parameters:
event
-
-
findNextMarker
public void findNextMarker()
-
findPreviousMarker
public void findPreviousMarker()
-
clearAllMarkers
public void clearAllMarkers()
-
toggleMarker
public void toggleMarker()
-
layoutComponents
public void layoutComponents()
-
setFindText
public void setFindText(java.lang.String findText)
-
getFindText
public java.lang.String getFindText()
-
-