ch.sahits.codegen.core.util
Class BasicLogger

java.lang.Object
  extended by ch.sahits.codegen.core.util.BasicLogger
Direct Known Subclasses:
Logging, SahitsLogger

public class BasicLogger
extends java.lang.Object

Additional logger functionality shared by all loggers

Since:
2.1.0
Author:
Andi Hotz, Sahits GmbH

Constructor Summary
BasicLogger()
           
 
Method Summary
 void addException(java.lang.Exception e)
          Add a new exception to the once that already occurred
 void addMessage(java.lang.Class<?> causingClass, java.lang.String message)
          Add a new message to the container, if the message container does not already contain any message from the causing class
 java.lang.String getMessage(java.lang.Class<?> causingClass)
          Retrieve the problem message for a specific causing class
 java.util.List<java.lang.Exception> getThrownException()
          Retrieve all Exception this plugin has produced up to now
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

BasicLogger

public BasicLogger()
Method Detail

addMessage

public void addMessage(java.lang.Class<?> causingClass,
                       java.lang.String message)
Add a new message to the container, if the message container does not already contain any message from the causing class

Parameters:
causingClass - class that produces the problem
message - describing the problem

getMessage

public java.lang.String getMessage(java.lang.Class<?> causingClass)
Retrieve the problem message for a specific causing class

Parameters:
causingClass - class that produces the problem
Returns:
problem message or null if there was no problem from the specified class

addException

public void addException(java.lang.Exception e)
Add a new exception to the once that already occurred

Parameters:
e - Exception to be added.

getThrownException

public java.util.List<java.lang.Exception> getThrownException()
Retrieve all Exception this plugin has produced up to now

Returns:
List with exceptions