systemService
Return
a system service of type T.
This is a type-safe, concise alternative to getSystemService(Class), avoiding ::class.java shenanigans.
Example:
val statusBarManager = context.systemService<StatusBarManager>()Content copied to clipboard
See also
Throws
if the service is not available on the device.