Skip to main content
aboutsummaryrefslogtreecommitdiffstats
blob: 2cdf63814a0515eadae7e02521bc3f97b22481db (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
/*******************************************************************************
 * Copyright (c) 2006, 2011 IBM Corporation and others
 *
 * This program and the accompanying materials are made
 * available under the terms of the Eclipse Public License 2.0 which
 * accompanies this distribution, and is available at
 * https://www.eclipse.org/legal/epl-2.0/
 *
 * SPDX-License-Identifier: EPL-2.0
 ******************************************************************************/
package org.eclipse.equinox.log;

import org.osgi.service.log.*;

/**
 * Extends the OSGi Log Service's LogReaderService to allow better control of log listeners.
 * @ThreadSafe
 * @see LogListener
 * @since 3.7
 */
public interface ExtendedLogReaderService extends LogReaderService {
	/**
	 * Subscribes to <code>LogEntry</code> objects.
	 * 
	 * <p>
	 * This method registers a <code>LogListener</code> object with the Log Reader
	 * Service with a <code>LogFilter</code> to allow pre-filtering of interesting log entries.
	 * The <code>LogListener.logged(LogEntry)</code> method will be
	 * called for each <code>LogEntry</code> object placed into the log that matches the filter.
	 * 
	 * @param listener A <code>LogListener</code> object to register; the
	 *        <code>LogListener</code> object is used to receive <code>LogEntry</code>
	 *        objects.
	 * @param filter A <code>LogFilter</code> object to register; the
	 *        <code>LogFilter</code> object is used to filter <code>LogEntry</code>
	 *        objects before sending them to the associated <code>LogListener</code>.
	 * @see LogListener
	 * @see LogFilter
	 * @see LogEntry
	 * @see LogReaderService#addLogListener(LogListener)
	 */
	public void addLogListener(LogListener listener, LogFilter filter);
}

Back to the top