Main Page
Namespaces
Classes
Files
File List
File Members
wrappers
java
src
main
java
org
openkinect
freenect
util
Jdk14LogHandler.java
Go to the documentation of this file.
1
25
package
org.openkinect.freenect.util;
26
27
import
org
.
openkinect
.
freenect
.
Device
;
28
import
org
.
openkinect
.
freenect
.
LogHandler
;
29
import
org
.
openkinect
.
freenect
.
LogLevel
;
30
31
import
java.util.EnumMap;
32
import
java.util.logging.Level;
33
import
java.util.logging.Logger;
34
35
public
class
Jdk14LogHandler
implements
LogHandler
{
36
37
private
final
Logger
logger
= Logger.getLogger(
"freenect"
);
38
private
final
EnumMap<LogLevel, Level>
levelMap
=
new
EnumMap<LogLevel, Level>(
LogLevel
.class);
39
40
public
Jdk14LogHandler
() {
41
logger.setLevel(Level.ALL);
42
levelMap.put(
LogLevel
.
FATAL
, Level.SEVERE);
43
levelMap.put(
LogLevel
.
ERROR
, Level.SEVERE);
44
levelMap.put(
LogLevel
.
WARNING
, Level.WARNING);
45
levelMap.put(
LogLevel
.
NOTICE
, Level.CONFIG);
46
levelMap.put(
LogLevel
.
INFO
, Level.INFO);
47
levelMap.put(
LogLevel
.
DEBUG
, Level.FINE);
48
levelMap.put(
LogLevel
.
SPEW
, Level.FINER);
49
levelMap.put(
LogLevel
.
FLOOD
, Level.FINEST);
50
}
51
52
@Override
53
public
void
onMessage
(
Device
dev,
LogLevel
level, String msg) {
54
logger.log(levelMap.get(level),
"device "
+ dev.
getDeviceIndex
() +
": "
+ msg);
55
}
56
}
org.openkinect.freenect.Device
Definition:
Device.java:27
org.openkinect.freenect.LogLevel.DEBUG
DEBUG
Definition:
LogLevel.java:36
org.openkinect.freenect.util.Jdk14LogHandler.Jdk14LogHandler
Jdk14LogHandler()
Definition:
Jdk14LogHandler.java:40
org
org.openkinect
org.openkinect.freenect.LogLevel.FATAL
FATAL
Definition:
LogLevel.java:31
org.openkinect.freenect.LogLevel.NOTICE
NOTICE
Definition:
LogLevel.java:34
org.openkinect.freenect.util.Jdk14LogHandler.levelMap
final EnumMap< LogLevel, Level > levelMap
Definition:
Jdk14LogHandler.java:38
org.openkinect.freenect.LogLevel.SPEW
SPEW
Definition:
LogLevel.java:37
org.openkinect.freenect.LogLevel
Definition:
LogLevel.java:30
org.openkinect.freenect.util.Jdk14LogHandler.logger
final Logger logger
Definition:
Jdk14LogHandler.java:37
org.openkinect.freenect.LogLevel.ERROR
ERROR
Definition:
LogLevel.java:32
org.openkinect.freenect.Device.getDeviceIndex
abstract int getDeviceIndex()
org.openkinect.freenect.util.Jdk14LogHandler
Definition:
Jdk14LogHandler.java:35
org.openkinect.freenect.util.Jdk14LogHandler.onMessage
void onMessage(Device dev, LogLevel level, String msg)
Definition:
Jdk14LogHandler.java:53
org.openkinect.freenect.LogLevel.WARNING
WARNING
Definition:
LogLevel.java:33
org.openkinect.freenect.LogHandler
Definition:
LogHandler.java:27
org.openkinect.freenect
Definition:
Context.java:25
org.openkinect.freenect.LogLevel.FLOOD
FLOOD
Definition:
LogLevel.java:38
org.openkinect.freenect.LogLevel.INFO
INFO
Definition:
LogLevel.java:35
libfreenect
Author(s): Hector Martin, Josh Blake, Kyle Machulis, OpenKinect community
autogenerated on Mon Jun 10 2019 13:46:42