Enum HomeAuthorizationStatus
- All Implemented Interfaces:
Comparable<HomeAuthorizationStatus>
Whether the user has granted this app access to their home.
Unlike the health API, this question has an honest answer on every
backend: HomeKit publishes HMHomeManagerAuthorizationStatus and the
Google Home APIs publish the account and structure grant. There is no
read/write split -- a home is authorized as a whole, and what an app may do
to a particular accessory is a property of the accessory, not of the grant.
-
Enum Constant Summary
Enum ConstantsEnum ConstantDescriptionAccess granted.The user was asked and declined.The user has not been asked yet.Blocked by parental controls or device management.This port cannot answer the question because it has no backend to ask. -
Method Summary
Modifier and TypeMethodDescriptionstatic HomeAuthorizationStatusReturns the enum constant of this type with the specified name.static HomeAuthorizationStatus[]values()Returns an array containing the constants of this enum type, in the order they are declared.Methods inherited from class Enum
clone, compareTo, equals, getDeclaringClass, getEnumValues, hashCode, name, ordinal, setEnumValues, toString, valueOf
-
Enum Constant Details
-
NOT_DETERMINED
The user has not been asked yet. CallSmartHome.requestAuthorization(). -
AUTHORIZED
Access granted. -
RESTRICTED
Blocked by parental controls or device management. Asking again will not help. -
DENIED
The user was asked and declined. Recoverable only through the system settings; seeSmartHome.openHomeSettings(). -
UNKNOWN
This port cannot answer the question because it has no backend to ask. Returned by the inert fallback and by the local simulated home.
-
-
Method Details
-
values
Returns an array containing the constants of this enum type, in the order they are declared.- Returns:
- an array containing the constants of this enum type, in the order they are declared
-
valueOf
Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)- Parameters:
name- the name of the enum constant to be returned.- Returns:
- the enum constant with the specified name
- Throws:
IllegalArgumentException- if this enum type has no constant with the specified nameNullPointerException- if the argument is null
-