AppFunctionState


public final class AppFunctionState


Runtime state of an app function.

This holds properties of an app function that can change at runtime during the app's operation, such as whether the function is enabled.

This is distinct from androidx.appfunctions.metadata.AppFunctionMetadata, which represents the metadata that remains constant until the providing package is updated. While androidx.appfunctions.metadata.AppFunctionMetadata defines what a function is, the AppFunctionState defines its current operational status.

Summary

Public methods

boolean
equals(Object other)
final ArraySet<@NonNull AppFunctionActivityId>
@RequiresApi(value = 37)
getActivityIds()

The android.app.appfunctions.AppFunctionActivityIds this app function is associated with.

final @NonNull AppFunctionName

The AppFunctionName associated with this state.

int
final boolean

Whether this app function can be executed.

@NonNull String

Public methods

equals

public boolean equals(Object other)

getFunctionName

Added in 1.0.0-alpha11
public final @NonNull AppFunctionName getFunctionName()

The AppFunctionName associated with this state.

hashCode

public int hashCode()

isEnabled

Added in 1.0.0-alpha11
public final boolean isEnabled()

Whether this app function can be executed.

This can be false if:

toString

public @NonNull String toString()