Class Log
java.lang.Object
org.bgerp.util.Log
- Direct Known Subclasses:
Log
Logging wrapper around Log4j version 1 with additional functions from version 2
-
Field Summary
Fields -
Constructor Summary
ConstructorsModifierConstructorDescriptionprotectedLog(org.apache.log4j.Logger logger) Make private later, temporary protected for backward compatible inherited class -
Method Summary
Modifier and TypeMethodDescriptionvoidExecuteslog(Priority, String, Object...)withLevel.DEBUGvoidExecuteslog(Priority, String, Object...)withLevel.ERRORvoidLogs error message and stack tracevoidLogs error message fromeand stack tracestatic StringFormats message using pattern with substitutionsstatic LoggetLog()UsingStackLocatorUtilgets the caller's object and logger for its classstatic LogClass connected loggervoidExecuteslog(Priority, String, Object...)withLevel.INFObooleanfinal voidWraps function toLoggervoidExecuteslog(Priority, String, Object...)withLevel.TRACEvoidExecuteslog(Priority, String, Object...)withLevel.WARNvoidSpecial warn call for deprecation messagesvoidwarndClass(Class<?> deprecatedClass, Class<?> actualClass) Deprecation warning for a created class instancevoidDeprecation warning for a JSP callvoidwarndMethod(String deprecatedName) Deprecation warning for a called methodvoidwarndMethod(String deprecatedName, String actualName) Deprecation warning for a called method
-
Field Details
-
MSG_DEPRECATED_METHOD_WAS_CALLED
- See Also:
-
MSG_WS_CREATE_NEW_INSTANCE_INSTEAD
- See Also:
-
-
Constructor Details
-
Log
protected Log(org.apache.log4j.Logger logger) Make private later, temporary protected for backward compatible inherited class
-
-
Method Details
-
getLog
-
getLog
UsingStackLocatorUtilgets the caller's object and logger for its class- Returns:
- logger configured for the caller object's class
-
format
-
trace
-
debug
-
isDebugEnabled
public boolean isDebugEnabled()- Returns:
- is
Level.DEBUGenabled
-
info
-
warn
-
warnd
-
warndMethod
-
warndMethod
Deprecation warning for a called method- Parameters:
deprecatedName- the deprecated method name
-
warndClass
-
warndJsp
-
error
-
error
Logs error message fromeand stack trace- Parameters:
e- the exception
-
error
-
log
Wraps function toLogger- Parameters:
level-message-
-