public class NativeLog extends Object
The native library specifies that implementations of native log handlers (like that encapsulated within this class) must be thread-safe.
The default log level is libvlc_log_level_e.NOTICE
, this can be changed
by invoking setLevel(libvlc_log_level_e)
.
The native log requires vlc 2.1.0 or later.
Constructor and Description |
---|
NativeLog(LibVlc libvlc,
libvlc_instance_t instance)
Create a new native log component.
|
Modifier and Type | Method and Description |
---|---|
void |
addLogListener(LogEventListener listener)
Add a component to be notified of log messages.
|
libvlc_log_level_e |
getLevel()
Get the log threshold level.
|
void |
release()
Release the native log component.
|
void |
removeLogListener(LogEventListener listener)
Remove a component previously added so it is no longer notified of log messages.
|
void |
setLevel(libvlc_log_level_e logLevel)
Set the log threshold level.
|
public NativeLog(LibVlc libvlc, libvlc_instance_t instance)
libvlc
- native library instanceinstance
- libvlc instancepublic final void addLogListener(LogEventListener listener)
listener
- component to addpublic final void removeLogListener(LogEventListener listener)
listener
- component to removepublic final void setLevel(libvlc_log_level_e logLevel)
Only log messages that are equal to or exceed this threshold are notified to listeners.
logLevel
- log threshold levelpublic final libvlc_log_level_e getLevel()
public final void release()
Copyright © 2009–2015 Caprica Software Limited. All rights reserved.