Added in API level 34

ForegroundServiceTypeException


abstract class ForegroundServiceTypeException : ServiceStartNotAllowedException
InvalidForegroundServiceTypeException

Exception thrown when an app tries to start a foreground Service with an invalid type.

MissingForegroundServiceTypeException

Exception thrown when an app tries to start a foreground Service without a type.

Base exception thrown when an app tries to start a foreground Service without a valid type.

Summary

Public constructors

Constructor.

Inherited properties

Public constructors

ForegroundServiceTypeException

Added in API level 34
ForegroundServiceTypeException(message: String)

Constructor.

Parameters
message String: This value cannot be null.