Package com.adobe.granite.logging
Interface LogAnalyser
-
@ProviderType public interface LogAnalyserThe log analyzer is a service making log entries available based on a configuration. By default all log messages with log level ERROR are recorded. Additional configurations can be provided through thesetLogConfiguration(LogConfigurationEntry[])method. However, this configuration is not persisted and does not survive a restart.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description java.util.List<LogEntry>getLastLogEntries(int size)Get the last number of log entries.LogConfigurationEntry[]getLogConfiguration()Get the current log configurationvoidsetLogConfiguration(LogConfigurationEntry[] config)Set the new configurations
-
-
-
Method Detail
-
getLogConfiguration
LogConfigurationEntry[] getLogConfiguration()
Get the current log configuration- Returns:
- An array of configurations. The array might have the length zero.
-
setLogConfiguration
void setLogConfiguration(LogConfigurationEntry[] config)
Set the new configurations- Parameters:
config- An array of configurations ornullto remove all configs.
-
getLastLogEntries
java.util.List<LogEntry> getLastLogEntries(int size)
Get the last number of log entries.- Parameters:
size- The maximum number of log entries or-1to get all available entries.- Returns:
- A list of log entries
-
-