| Index: components/variations/android/java/src/org/chromium/components/variations/VariationsAssociatedData.java
|
| diff --git a/components/variations/android/java/src/org/chromium/components/variations/VariationsAssociatedData.java b/components/variations/android/java/src/org/chromium/components/variations/VariationsAssociatedData.java
|
| index 8d7264d780a7b94b646f7d4e92d85c467cf044ee..084aad38709ac083293576d0e00e1c464c8bbae6 100644
|
| --- a/components/variations/android/java/src/org/chromium/components/variations/VariationsAssociatedData.java
|
| +++ b/components/variations/android/java/src/org/chromium/components/variations/VariationsAssociatedData.java
|
| @@ -18,6 +18,18 @@ public final class VariationsAssociatedData {
|
| }
|
|
|
| /**
|
| + * @param feature Native reference of the feature to get the param as integer for.
|
| + * @param paramName The name of the param for which to get as an integer.
|
| + * @param defaultValue The integer value to use if the param is not available.
|
| + * @return The parameter value as an int. Default value if the feature does not exist or the
|
| + * specified parameter does not exist.
|
| + */
|
| + public static int getVariationParamByFeatureAsInt(
|
| + long feature, String paramName, int defaultValue) {
|
| + return nativeGetVariationParamByFeatureAsInt(feature, paramName, defaultValue);
|
| + }
|
| +
|
| + /**
|
| * @param trialName The name of the trial to get the param value for.
|
| * @param paramName The name of the param for which to get the value.
|
| * @return The parameter value. Empty string if the field trial does not exist or the specified
|
| @@ -35,4 +47,6 @@ public final class VariationsAssociatedData {
|
|
|
| private static native String nativeGetVariationParamValue(String trialName, String paramName);
|
| private static native String nativeGetFeedbackVariations();
|
| + private static native int nativeGetVariationParamByFeatureAsInt(
|
| + long feature, String paramName, int defaultValue);
|
| }
|
|
|