public static ContextLoggerConfiguration getOrCreateContextLoggerConfiguration() { if (contextLoggerConfiguration == null) { contextLoggerConfiguration = new ContextLoggerConfiguration(); } return contextLoggerConfiguration; }
public static ContextLoggerBuilder create() { return new ContextLoggerBuilderImpl(ContextLoggerConfiguration.getOrCreateContextLoggerConfiguration()); }
return createInstance(contextLoggerConfiguration.getImplicitContextClassMap().get(instance)); Class knownWrapperType = contextLoggerConfiguration.getClassToWrapperMap().get(instance.getClass()); if (knownWrapperType != null) { Object wrappedInstance = createInstance(knownWrapperType); for (TypeToWrapper wrapper : contextLoggerConfiguration.getWrapperList()) { if (wrapper.getWrappedInstanceType().isAssignableFrom(instance.getClass())) { try {
/** * Creates a TraceeGsonContextLogBuilder instance which can be used for creating the log message. * * @return An instance of TraceeGsonContextLogBuilder */ private TraceeGsonContextLogBuilder createGsonLogBuilder() { TraceeGsonContextLogBuilder tmpTraceeGsonContextLogBuilder = new TraceeGsonContextLogBuilder(); tmpTraceeGsonContextLogBuilder.setWrapperClasses(contextLoggerConfiguration.getWrapperClasses()); tmpTraceeGsonContextLogBuilder.setManualContextOverrides(configBuilder.getManualContextOverrides()); tmpTraceeGsonContextLogBuilder.setProfile(this.configBuilder.getProfile()); return tmpTraceeGsonContextLogBuilder; } }