Interface AccessLogWriter
-
- Functional Interface:
- This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.
@FunctionalInterface public interface AccessLogWriter
Consumes theRequestLog
s produced by aServer
, usually for logging purpose.
-
-
Method Summary
All Methods Static Methods Instance Methods Abstract Methods Default Methods Modifier and Type Method Description default AccessLogWriter
andThen(AccessLogWriter after)
Returns a newAccessLogWriter
which combines twoAccessLogWriter
s.static AccessLogWriter
combined()
Returns an access log writer with a combined format.static AccessLogWriter
common()
Returns an access log writer with a common format.static AccessLogWriter
custom(String formatStr)
Returns an access log writer with the specifiedformatStr
.static AccessLogWriter
disabled()
Returns disabled access log writer.void
log(RequestLog log)
Logs the specifiedRequestLog
.default CompletableFuture<Void>
shutdown()
Shuts down thisAccessLogWriter
.
-
-
-
Method Detail
-
common
static AccessLogWriter common()
Returns an access log writer with a common format.
-
combined
static AccessLogWriter combined()
Returns an access log writer with a combined format.
-
disabled
static AccessLogWriter disabled()
Returns disabled access log writer.
-
custom
static AccessLogWriter custom(String formatStr)
Returns an access log writer with the specifiedformatStr
.
-
log
void log(RequestLog log) throws Exception
Logs the specifiedRequestLog
.- Throws:
Exception
-
andThen
default AccessLogWriter andThen(AccessLogWriter after)
Returns a newAccessLogWriter
which combines twoAccessLogWriter
s.
-
shutdown
default CompletableFuture<Void> shutdown()
Shuts down thisAccessLogWriter
.- Returns:
- the
CompletableFuture
which is completed when thisAccessLogWriter
has been shut down.
-
-