KeyValueBuilder

classKeyValueBuilder


Helper class to enable convenient syntax insetCustomKeys andrecordException

Summary

Public functions

Unit
key(key: String, value: Boolean)

Sets a custom key and value that are associated with reports.

Unit
key(key: String, value: Double)

Sets a custom key and value that are associated with reports.

Unit
key(key: String, value: Float)

Sets a custom key and value that are associated with reports.

Unit
key(key: String, value: Int)

Sets a custom key and value that are associated with reports.

Unit
key(key: String, value: Long)

Sets a custom key and value that are associated with reports.

Unit
key(key: String, value: String)

Sets a custom key and value that are associated with reports.

Public functions

key

fun key(key: String, value: Boolean): Unit

Sets a custom key and value that are associated with reports.

key

fun key(key: String, value: Double): Unit

Sets a custom key and value that are associated with reports.

key

fun key(key: String, value: Float): Unit

Sets a custom key and value that are associated with reports.

key

fun key(key: String, value: Int): Unit

Sets a custom key and value that are associated with reports.

key

fun key(key: String, value: Long): Unit

Sets a custom key and value that are associated with reports.

key

fun key(key: String, value: String): Unit

Sets a custom key and value that are associated with reports.

Except as otherwise noted, the content of this page is licensed under theCreative Commons Attribution 4.0 License, and code samples are licensed under theApache 2.0 License. For details, see theGoogle Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates.

Last updated 2025-07-21 UTC.