]> git.argeo.org Git - gpl/argeo-slc.git/blob - runtime/org.argeo.slc.support.maven/src/main/java/org/argeo/slc/maven/embedder/PlexusLoggerAdapter.java
Add license headers
[gpl/argeo-slc.git] / runtime / org.argeo.slc.support.maven / src / main / java / org / argeo / slc / maven / embedder / PlexusLoggerAdapter.java
1 /*
2 * Copyright (C) 2010 Mathieu Baudier <mbaudier@argeo.org>
3 *
4 * Licensed under the Apache License, Version 2.0 (the "License");
5 * you may not use this file except in compliance with the License.
6 * You may obtain a copy of the License at
7 *
8 * http://www.apache.org/licenses/LICENSE-2.0
9 *
10 * Unless required by applicable law or agreed to in writing, software
11 * distributed under the License is distributed on an "AS IS" BASIS,
12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13 * See the License for the specific language governing permissions and
14 * limitations under the License.
15 */
16
17 package org.argeo.slc.maven.embedder;
18
19 import org.codehaus.plexus.logging.Logger;/*
20 * Copyright 2001-2005 The Apache Software Foundation.
21 *
22 * Licensed under the Apache License, Version 2.0 (the "License");
23 * you may not use this file except in compliance with the License.
24 * You may obtain a copy of the License at
25 *
26 * http://www.apache.org/licenses/LICENSE-2.0
27 *
28 * Unless required by applicable law or agreed to in writing, software
29 * distributed under the License is distributed on an "AS IS" BASIS,
30 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
31 * See the License for the specific language governing permissions and
32 * limitations under the License.
33 */
34
35 /**
36 * @author <a href="mailto:jason@maven.org">Jason van Zyl</a>
37 * @version $Id: PlexusLoggerAdapter.java 293410 2005-10-03 18:06:00Z jdcasey $
38 */
39 public class PlexusLoggerAdapter
40 implements Logger
41 {
42 private MavenEmbedderLogger logger;
43
44 public PlexusLoggerAdapter( MavenEmbedderLogger logger )
45 {
46 this.logger = logger;
47 }
48
49 public void debug( String message )
50 {
51 logger.debug( message );
52 }
53
54 public void debug( String message, Throwable throwable )
55 {
56 logger.debug( message, throwable );
57 }
58
59 public boolean isDebugEnabled()
60 {
61 return logger.isDebugEnabled();
62 }
63
64 public void info( String message )
65 {
66 logger.info( message );
67 }
68
69 public void info( String message, Throwable throwable )
70 {
71 logger.info( message, throwable );
72 }
73
74 public boolean isInfoEnabled()
75 {
76 return logger.isInfoEnabled();
77 }
78
79 public void warn( String message )
80 {
81 logger.warn( message );
82 }
83
84 public void warn( String message, Throwable throwable )
85 {
86 logger.warn( message, throwable );
87 }
88
89 public boolean isWarnEnabled()
90 {
91 return logger.isWarnEnabled();
92 }
93
94 public void error( String message )
95 {
96 logger.error( message );
97 }
98
99 public void error( String message, Throwable throwable )
100 {
101 logger.error( message );
102 }
103
104 public boolean isErrorEnabled()
105 {
106 return logger.isErrorEnabled();
107 }
108
109 public void fatalError( String message )
110 {
111 logger.fatalError( message );
112 }
113
114 public void fatalError( String message, Throwable throwable )
115 {
116 logger.fatalError( message, throwable );
117 }
118
119 public boolean isFatalErrorEnabled()
120 {
121 return logger.isFatalErrorEnabled();
122 }
123
124 public void setThreshold( int i )
125 {
126 logger.setThreshold( i );
127 }
128
129 public int getThreshold()
130 {
131 return logger.getThreshold();
132 }
133
134 public String getName()
135 {
136 return toString();
137 }
138
139 public Logger getChildLogger( String name )
140 {
141 return this;
142 }
143 }