interface LoggerInterface in Ultimate Cron 8.2
Defines a logger method.
Hierarchy
- interface \Drupal\Component\Plugin\PluginInspectionInterface; interface \Drupal\Component\Plugin\ConfigurableInterface; interface \Drupal\Component\Plugin\DependentPluginInterface; interface \Drupal\Core\Plugin\PluginFormInterface
- interface \Drupal\ultimate_cron\Logger\LoggerInterface
Expanded class hierarchy of LoggerInterface
All classes that implement LoggerInterface
File
- src/
Logger/ LoggerInterface.php, line 13
Namespace
Drupal\ultimate_cron\LoggerView source
interface LoggerInterface extends PluginInspectionInterface, ConfigurableInterface, DependentPluginInterface, PluginFormInterface {
/**
* Returns the default configuration.
*
* @return mixed
*/
public function defaultConfiguration();
/**
* Factory method for creating a new unsaved log entry object.
*
* @param string $name
* Name of the log entry (name of the job).
*
* @return LogEntry
* The log entry.
*/
public function factoryLogEntry($name);
/**
* Create a new log entry.
*
* @param string $name
* Name of the log entry (name of the job).
* @param string $lock_id
* The lock id.
* @param string $init_message
* (optional) The initial message for the log entry.
* @param int $log_type
* (optional) The log_type for the log entry.
*
* @return LogEntry
* The log entry created.
*/
public function createEntry($name, $lock_id, $init_message = '', $log_type = ULTIMATE_CRON_LOG_TYPE_NORMAL);
/**
* Load latest log entry for multiple jobs.
*
* This is the fallback method. Loggers should implement an optimized
* version if possible.
*
* @param array $jobs
* Jobs for which the log entries should be loaded.
* @param array $log_types
* Type of log messages to load.
*/
public function loadLatestLogEntries(array $jobs, array $log_types);
/**
* Load a log.
*
* @param string $name
* Name of log.
* @param string $lock_id
* Specific lock id.
*
* @return \Drupal\ultimate_cron\Logger\LogEntry
* Log entry
*/
public function load($name, $lock_id = NULL, array $log_types = [
ULTIMATE_CRON_LOG_TYPE_NORMAL,
]);
/**
* Get page with log entries for a job.
*
* @param string $name
* Name of job.
* @param array $log_types
* Log types to get.
* @param int $limit
* (optional) Number of log entries per page.
*
* @return array
* Log entries.
*/
public function getLogEntries($name, array $log_types, $limit = 10);
/**
* Saves a log entry.
*
* @param \Drupal\ultimate_cron\Logger\LogEntry $log_entry
* The log entry to save.
*/
public function save(LogEntry $log_entry);
}
Members
Name | Modifiers | Type | Description | Overrides |
---|---|---|---|---|
ConfigurableInterface:: |
public | function | Gets this plugin's configuration. | 12 |
ConfigurableInterface:: |
public | function | Sets the configuration for this plugin instance. | 12 |
DependentPluginInterface:: |
public | function | Calculates dependencies for the configured plugin. | 19 |
LoggerInterface:: |
public | function | Create a new log entry. | 1 |
LoggerInterface:: |
public | function |
Returns the default configuration. Overrides ConfigurableInterface:: |
|
LoggerInterface:: |
public | function | Factory method for creating a new unsaved log entry object. | 1 |
LoggerInterface:: |
public | function | Get page with log entries for a job. | 2 |
LoggerInterface:: |
public | function | Load a log. | 2 |
LoggerInterface:: |
public | function | Load latest log entry for multiple jobs. | 1 |
LoggerInterface:: |
public | function | Saves a log entry. | 2 |
PluginFormInterface:: |
public | function | Form constructor. | 36 |
PluginFormInterface:: |
public | function | Form submission handler. | 32 |
PluginFormInterface:: |
public | function | Form validation handler. | 18 |
PluginInspectionInterface:: |
public | function | Gets the definition of the plugin implementation. | 4 |
PluginInspectionInterface:: |
public | function | Gets the plugin_id of the plugin instance. | 2 |