Class MapBuilder
java.lang.Object
io.dropwizard.logging.json.layout.MapBuilder
Builds a Java map based on the provided configuration and customization.
-
Constructor Summary
ConstructorsConstructorDescriptionMapBuilder
(TimestampFormatter timestampFormatter, Map<String, String> customFieldNames, Map<String, Object> additionalFields, int expectedSize) -
Method Summary
Modifier and TypeMethodDescriptionAdds the string value to the provided map under the provided field name, if it should be included.Adds the map to the provided map under the provided field name if it's should be included.Adds the string value to the provided map under the provided field name, if it should be included.Adds the map value to the provided map under the provided field name, if it should be included.Adds the number to the provided map under the provided field name if it's should be included.Adds the number value to the provided map under the provided field name, if it should be included.addTimestamp
(String fieldName, boolean include, long timestamp) Adds and optionally formats the timestamp to the provided map under the provided field name, if it's should be included.build()
-
Constructor Details
-
MapBuilder
-
-
Method Details
-
add
Adds the string value to the provided map under the provided field name, if it should be included. -
add
Adds the string value to the provided map under the provided field name, if it should be included. The supplier is only invoked if the field is to be included.- Since:
- 2.0
-
addNumber
Adds the number to the provided map under the provided field name if it's should be included. -
addNumber
Adds the number value to the provided map under the provided field name, if it should be included. The supplier is only invoked if the field is to be included.- Since:
- 2.0
-
add
Adds the map to the provided map under the provided field name if it's should be included. -
addMap
Adds the map value to the provided map under the provided field name, if it should be included. The supplier is only invoked if the field is to be included.- Since:
- 2.0
-
addTimestamp
Adds and optionally formats the timestamp to the provided map under the provided field name, if it's should be included. -
build
-