Package eu.svjatoslav.sixth.e3d.gui
Class DebugLogBuffer
java.lang.Object
eu.svjatoslav.sixth.e3d.gui.DebugLogBuffer
Circular buffer for debug log messages.
Captures log messages to a fixed-size circular buffer for display
in the DeveloperToolsPanel.
This allows capturing early initialization logs before the user opens the Developer Tools panel. When the panel is opened, the buffered history becomes immediately visible.
- See Also:
-
Constructor Summary
ConstructorsConstructorDescriptionDebugLogBuffer(int capacity) Creates a new DebugLogBuffer with the specified capacity. -
Method Summary
-
Constructor Details
-
DebugLogBuffer
public DebugLogBuffer(int capacity) Creates a new DebugLogBuffer with the specified capacity.- Parameters:
capacity- the maximum number of log entries to retain
-
-
Method Details
-
log
Logs a message with a timestamp prefix.- Parameters:
message- the message to log
-
getEntries
Returns all buffered log entries in chronological order.- Returns:
- a list of timestamped log entries
-
clear
public void clear()Clears all buffered log entries. -
size
public int size()Returns the current number of log entries in the buffer.- Returns:
- the number of entries
-