Trust Pin Log Sink
Destination for TrustPin SDK log output.
By default the SDK writes to Android's logcat (via android.util.Log, with severities mapped to Log.e/Log.i/Log.d) when running on Android, and to standard output on the JVM. Install a sink with TrustPin.setLogSink to route SDK logs into the host app's logging pipeline instead (Timber, SLF4J, a file logger, an in-app console, …).
The sink is global: one sink receives the output of every TrustPin instance, distinguished by instanceId. What is logged — and at which verbosity — is still controlled per instance via TrustPin.setLogLevel; the sink only chooses where already-filtered messages go.
Implementations must be thread-safe and fast: messages are delivered synchronously from SDK internals, including threads performing TLS handshakes. Do not block, perform I/O beyond lightweight appends, or call back into TrustPin from log.