Inspectopedia Help

Wrong system service casts

Wrong system service casts

When you call Context#getSystemService(), the result is typically cast to a specific interface. This lint check ensures that the cast is compatible with the expected type of the return value.

Issue id: ServiceCast

Inspection Details

Available in:

IntelliJ IDEA 2023.3, Qodana for Android 2023.3, Qodana for JVM 2023.3


Android, 2022.3.1 Beta 2

Last modified: 13 July 2023