View Javadoc
1   package org.apache.maven.scm.plugin;
2   
3   /*
4    * Licensed to the Apache Software Foundation (ASF) under one
5    * or more contributor license agreements.  See the NOTICE file
6    * distributed with this work for additional information
7    * regarding copyright ownership.  The ASF licenses this file
8    * to you under the Apache License, Version 2.0 (the
9    * "License"); you may not use this file except in compliance
10   * with the License.  You may obtain a copy of the License at
11   *
12   * http://www.apache.org/licenses/LICENSE-2.0
13   *
14   * Unless required by applicable law or agreed to in writing,
15   * software distributed under the License is distributed on an
16   * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
17   * KIND, either express or implied.  See the License for the
18   * specific language governing permissions and limitations
19   * under the License.
20   */
21  
22  import org.apache.maven.plugin.logging.Log;
23  import org.apache.maven.scm.log.ScmLogger;
24  
25  /**
26   * @author <a href="mailto:evenisse@apache.org">Emmanuel Venisse</a>
27   */
28  public class DefaultLog
29      implements ScmLogger
30  {
31      private Log logger;
32  
33      public DefaultLog( Log logger )
34      {
35          this.logger = logger;
36      }
37  
38      /** {@inheritDoc} */
39      public boolean isDebugEnabled()
40      {
41          return logger.isDebugEnabled();
42      }
43  
44      /** {@inheritDoc} */
45      public void debug( String content )
46      {
47          logger.debug( content );
48      }
49  
50      /** {@inheritDoc} */
51      public void debug( String content, Throwable error )
52      {
53          logger.debug( content, error );
54      }
55  
56      /** {@inheritDoc} */
57      public void debug( Throwable error )
58      {
59          logger.debug( error );
60      }
61  
62      /** {@inheritDoc} */
63      public boolean isInfoEnabled()
64      {
65          return logger.isInfoEnabled();
66      }
67  
68      /** {@inheritDoc} */
69      public void info( String content )
70      {
71          logger.info( content );
72      }
73  
74      /** {@inheritDoc} */
75      public void info( String content, Throwable error )
76      {
77          logger.info( content, error );
78      }
79  
80      /** {@inheritDoc} */
81      public void info( Throwable error )
82      {
83          logger.info( error );
84      }
85  
86      /** {@inheritDoc} */
87      public boolean isWarnEnabled()
88      {
89          return logger.isWarnEnabled();
90      }
91  
92      /** {@inheritDoc} */
93      public void warn( String content )
94      {
95          logger.warn( content );
96      }
97  
98      /** {@inheritDoc} */
99      public void warn( String content, Throwable error )
100     {
101         logger.warn( content, error );
102     }
103 
104     /** {@inheritDoc} */
105     public void warn( Throwable error )
106     {
107         logger.warn( error );
108     }
109 
110     /** {@inheritDoc} */
111     public boolean isErrorEnabled()
112     {
113         return logger.isErrorEnabled();
114     }
115 
116     /** {@inheritDoc} */
117     public void error( String content )
118     {
119         logger.error( content );
120     }
121 
122     /** {@inheritDoc} */
123     public void error( String content, Throwable error )
124     {
125         logger.error( content, error );
126     }
127 
128     /** {@inheritDoc} */
129     public void error( Throwable error )
130     {
131         logger.error( error );
132     }
133 }