Logging

io.bullet.borer.Logging
object Logging

Facilities for on-the-side logging of either encoding or decoding progress, which can be useful for debugging problems with the input or custom codec logic.

Logging can be done either before or after the input validation step, depending on your needs. If unsure, go for after-validation logging, at least initially. (This is also the default.) For example, to log decoding progress to the console you can say:

Cbor.decode(inputBytes).withPrintLogging().to[MyType]

Attributes

Graph
Supertypes
class Object
trait Matchable
class Any
Self type
Logging.type

Members list

Type members

Classlikes

object ElementType

Attributes

Companion
trait
Supertypes
trait Sum
trait Mirror
class Object
trait Matchable
class Any
Self type
sealed trait ElementType

Attributes

Companion
object
Supertypes
class Object
trait Matchable
class Any
Known subtypes
object ArrayElement.type
trait MapEntry
object MapKey.type
object MapValue.type
Show all
trait LevelInfo

Attributes

Supertypes
class Object
trait Matchable
class Any
Known subtypes
class Receiver
abstract class LineFormatLogger extends Logger

A Logger which formats each incoming element to it's own log line.

A Logger which formats each incoming element to it's own log line.

Attributes

Supertypes
trait Logger
class Object
trait Matchable
class Any
Known subtypes
trait Logger

Attributes

Supertypes
class Object
trait Matchable
class Any
Known subtypes
class PrintLogger(val info: LevelInfo, val maxShownByteArrayPrefixLen: Int, val maxShownStringPrefixLen: Int, val maxShownArrayElems: Int, val maxShownMapEntries: Int, val initialGutterWidth: Int, val renderLevelCount: Boolean, val renderEndOfInput: Boolean, val renderCommas: Boolean, val indentation: String, val mapKeySep: String) extends LineFormatLogger

A LineFormatLogger that simply prints all lines to the console.

A LineFormatLogger that simply prints all lines to the console.

Attributes

Supertypes
trait Logger
class Object
trait Matchable
class Any
final class Receiver(target: Receiver, createLogger: LevelInfo => Logger) extends Receiver, LevelInfo

A Receiver which forwards all incoming data item to another Receiver and, on the side, feeds a custom Logger with logging events.

A Receiver which forwards all incoming data item to another Receiver and, on the side, feeds a custom Logger with logging events.

Attributes

Supertypes
trait LevelInfo
class Receiver
class Object
trait Matchable
class Any
class ToStringLogger(val info: LevelInfo, val stringBuilder: StringBuilder, val maxShownByteArrayPrefixLen: Int, val maxShownStringPrefixLen: Int, val maxShownArrayElems: Int, val maxShownMapEntries: Int, val initialGutterWidth: Int, val renderLevelCount: Boolean, val renderEndOfInput: Boolean, val renderCommas: Boolean, val indentation: String, val mapKeySep: String, val lineSep: String, val mapValueOnNewLine: Boolean) extends LineFormatLogger

A LineFormatLogger that appends all lines to a given JStringBuilder.

A LineFormatLogger that appends all lines to a given JStringBuilder.

Attributes

Supertypes
trait Logger
class Object
trait Matchable
class Any

Value members

Concrete methods

def transformer[Config](createLogger: LevelInfo => Logger): () => Config