Loading tools/aconfig/aconfig/templates/FeatureFlagsImpl.java.template +4 −0 Original line number Diff line number Diff line Loading @@ -125,6 +125,7 @@ import android.compat.annotation.UnsupportedAppUsage; {{ -endif }} {{ -if runtime_lookup_required }} import android.os.Binder; import android.provider.DeviceConfig; import android.provider.DeviceConfig.Properties; {{ -endif }} Loading @@ -142,6 +143,7 @@ public final class FeatureFlagsImpl implements FeatureFlags \{ {{ -endfor }} {{ for namespace_with_flags in namespace_flags }} private void load_overrides_{namespace_with_flags.namespace}() \{ final long ident = Binder.clearCallingIdentity(); try \{ Properties properties = DeviceConfig.getProperties("{namespace_with_flags.namespace}"); {{ -for flag in namespace_with_flags.flags }} Loading @@ -159,6 +161,8 @@ public final class FeatureFlagsImpl implements FeatureFlags \{ + "flag declaration.", e ); } finally \{ Binder.restoreCallingIdentity(ident); } {namespace_with_flags.namespace}_is_cached = true; } Loading Loading
tools/aconfig/aconfig/templates/FeatureFlagsImpl.java.template +4 −0 Original line number Diff line number Diff line Loading @@ -125,6 +125,7 @@ import android.compat.annotation.UnsupportedAppUsage; {{ -endif }} {{ -if runtime_lookup_required }} import android.os.Binder; import android.provider.DeviceConfig; import android.provider.DeviceConfig.Properties; {{ -endif }} Loading @@ -142,6 +143,7 @@ public final class FeatureFlagsImpl implements FeatureFlags \{ {{ -endfor }} {{ for namespace_with_flags in namespace_flags }} private void load_overrides_{namespace_with_flags.namespace}() \{ final long ident = Binder.clearCallingIdentity(); try \{ Properties properties = DeviceConfig.getProperties("{namespace_with_flags.namespace}"); {{ -for flag in namespace_with_flags.flags }} Loading @@ -159,6 +161,8 @@ public final class FeatureFlagsImpl implements FeatureFlags \{ + "flag declaration.", e ); } finally \{ Binder.restoreCallingIdentity(ident); } {namespace_with_flags.namespace}_is_cached = true; } Loading