You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
* Enhance Android Logging with setLogCallback API
This change adds the setLogCallback API to the AndroidChipLogging class
of the Matter SDK, enhancing its logging capabilities. With this API,
developers can customize logging behavior and integrate it with
Android's logging system, allowing for more flexible and comprehensive
logging.
An example of usage in Kotlin is as follows:
ChipDeviceController.loadJni()
AndroidChipLogging.setLogCallback { module, priority, message ->
when (priority) {
Log.ERROR -> Log.e(module, message)
Log.INFO -> Log.i(module, message)
Log.DEBUG -> Log.d(module, message)
}
}
Signed-off-by: Youngho Yoon <34558998+yhoyoon@users.noreply.github.com>
* Add s prefix for global variables
Signed-off-by: Youngho Yoon <34558998+yhoyoon@users.noreply.github.com>
* Do not call onLogMessage callback when msg is null
Handle the case where jMsg is null due to UTF decode errors in buffer.
Don't call the callback when the string is null.
Signed-off-by: Youngho Yoon <34558998+yhoyoon@users.noreply.github.com>
* Return logRedirectCallback when env is nullptr
Signed-off-by: Youngho Yoon <34558998+yhoyoon@users.noreply.github.com>
* Use JniLocalReferenceScope instead of DeleteLocalRef
Signed-off-by: Youngho Yoon <34558998+yhoyoon@users.noreply.github.com>
* Change type of global ref to JniGlobalReference
Signed-off-by: Youngho Yoon <34558998+yhoyoon@users.noreply.github.com>
* Use CharToStringUTF instead of NewStringUTF
Signed-off-by: Youngho Yoon <34558998+yhoyoon@users.noreply.github.com>
* Use VerifyOrReturn for CharToStringUTF
Signed-off-by: Youngho Yoon <34558998+yhoyoon@users.noreply.github.com>
---------
Signed-off-by: Youngho Yoon <34558998+yhoyoon@users.noreply.github.com>
0 commit comments