public class LogEventFactory extends Object
Constructor and Description |
---|
LogEventFactory() |
Modifier and Type | Method and Description |
---|---|
static <T extends AuditEvent> |
getEvent(Class<T> intrface)
Constructs an Event object from its interface.
|
static List<String> |
getPropertyNames(String className) |
static void |
logEvent(AuditMessage msg,
AuditExceptionHandler handler)
Used to Log the actual AuditMessage.
|
static void |
logEvent(Class<?> intrface,
Map<String,String> properties)
This method is used to construct and AuditMessage from a set of properties and the Event interface
that represents the event being audited using the default error handler.
|
static void |
logEvent(Class<?> intrface,
Map<String,String> properties,
AuditExceptionHandler handler)
This method is used to construct and AuditMessage from a set of properties and the Event interface
that represents the event being audited.
|
static void |
setDefaultHandler(AuditExceptionHandler exceptionHandler) |
public static void setDefaultHandler(AuditExceptionHandler exceptionHandler)
public static <T extends AuditEvent> T getEvent(Class<T> intrface)
T
- The Event type.intrface
- The Event interface.public static void logEvent(Class<?> intrface, Map<String,String> properties)
intrface
- The Event interface.properties
- The properties to be included in the event.public static void logEvent(Class<?> intrface, Map<String,String> properties, AuditExceptionHandler handler)
intrface
- The Event interface.properties
- The properties to be included in the event.handler
- Class that gets control when an exception occurs logging the event.public static void logEvent(AuditMessage msg, AuditExceptionHandler handler)
msg
- The AuditMessage.handler
- Class that gets control when an exception occurs logging the event.Copyright © 2016-2018 Apache Software Foundation. All Rights Reserved.
Apache Logging, Apache Log4j, Apache Log4j Audit, Log4j, Log4j Audit, Apache, the Apache feather logo, the Apache Logging project logo, and the Apache Log4j logo are trademarks of The Apache Software Foundation.