Update Runtime metadata property config

Flag: android.app.appfunctions.flags.enable_app_function_manager
Test: Existing
Bug: 357551503
Change-Id: Ifcb9ade3421e5f9f196eef68aa4e9b76bd6aa1dd
diff --git a/core/java/android/app/appfunctions/AppFunctionRuntimeMetadata.java b/core/java/android/app/appfunctions/AppFunctionRuntimeMetadata.java
index 08ecced..06d95f5 100644
--- a/core/java/android/app/appfunctions/AppFunctionRuntimeMetadata.java
+++ b/core/java/android/app/appfunctions/AppFunctionRuntimeMetadata.java
@@ -137,8 +137,10 @@
                                                 .TOKENIZER_TYPE_VERBATIM)
                                 .build())
                 .addProperty(
-                        new AppSearchSchema.BooleanPropertyConfig.Builder(PROPERTY_ENABLED)
+                        new AppSearchSchema.LongPropertyConfig.Builder(PROPERTY_ENABLED)
                                 .setCardinality(AppSearchSchema.PropertyConfig.CARDINALITY_OPTIONAL)
+                                .setIndexingType(
+                                        AppSearchSchema.LongPropertyConfig.INDEXING_TYPE_RANGE)
                                 .build())
                 .addProperty(
                         new AppSearchSchema.StringPropertyConfig.Builder(
@@ -212,19 +214,14 @@
         }
 
         /**
-         * Sets an indicator specifying if the function is enabled or not. This would override the
-         * default enabled state in the static metadata ({@link
-         * AppFunctionStaticMetadataHelper#STATIC_PROPERTY_ENABLED_BY_DEFAULT}). Sets this to null
-         * to clear the override.
-         * TODO(369683073) Replace the tristate Boolean with IntDef EnabledState.
+         * Sets an indicator specifying the function enabled state.
          */
         @NonNull
         public Builder setEnabled(@EnabledState int enabledState) {
             if (enabledState != APP_FUNCTION_STATE_DEFAULT
                     && enabledState != APP_FUNCTION_STATE_ENABLED
                     && enabledState != APP_FUNCTION_STATE_DISABLED) {
-                throw new IllegalArgumentException(
-                        "Value of EnabledState is unsupported.");
+                throw new IllegalArgumentException("Value of EnabledState is unsupported.");
             }
             setPropertyLong(PROPERTY_ENABLED, enabledState);
             return this;