main.app.cash.paparazzi.internal.interceptors.ServiceManagerInterceptor.kt Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of paparazzi Show documentation
Show all versions of paparazzi Show documentation
An Android library to render your application screens without a physical device or emulator
The newest version!
package app.cash.paparazzi.internal.interceptors
import android.os.IBinder
/**
* The ImeTracing class attempts to initialize its [mService field in its constructor](https://cs.android.com/android/platform/superproject/+/master:frameworks/base/core/java/android/util/imetracing/ImeTracing.java;l=60).
*
* Unfortunately, [layoutlib's version of ServiceManager](https://cs.android.com/android/platform/superproject/+/master:frameworks/layoutlib/bridge/src/android/os/ServiceManager.java;l=37)
* throws an exception immediately.
*
* This interceptor overrides ServiceManager.getServiceOrThrow to simply return null instead.
*/
internal object ServiceManagerInterceptor {
@Suppress("unused")
@JvmStatic
fun interceptGetServiceOrThrow(@Suppress("UNUSED_PARAMETER") name: String): IBinder? = null
}