Chromium Code Reviews| Index: chrome/android/java/src/org/chromium/chrome/browser/net/spdyproxy/DataReductionProxySettings.java |
| diff --git a/chrome/android/java/src/org/chromium/chrome/browser/net/spdyproxy/DataReductionProxySettings.java b/chrome/android/java/src/org/chromium/chrome/browser/net/spdyproxy/DataReductionProxySettings.java |
| index d378b5d9e34e868f9b8ab9bd59c7d364a8b6cc40..378651f7edeac72f4209937b349fc1f4e162a18a 100644 |
| --- a/chrome/android/java/src/org/chromium/chrome/browser/net/spdyproxy/DataReductionProxySettings.java |
| +++ b/chrome/android/java/src/org/chromium/chrome/browser/net/spdyproxy/DataReductionProxySettings.java |
| @@ -98,13 +98,6 @@ public class DataReductionProxySettings { |
| } |
| /** |
| - * Returns a configuration string for the data reduction proxy. |
| - */ |
| - public String getDataReductionProxyAuth() { |
| - return nativeGetDataReductionProxyAuth(mNativeDataReductionProxySettings); |
| - } |
| - |
| - /** |
| * Sets the preference on whether to enable/disable the SPDY proxy. This will zero out the |
| * data reduction statistics if this is the first time the SPDY proxy has been enabled. |
| */ |
| @@ -139,6 +132,25 @@ public class DataReductionProxySettings { |
| } |
| /** |
| + * Returns true if the host and realm (as passed in to Tab.onReceivedHttpAuthRequest()) are such |
|
David Trainor- moved to gerrit
2013/10/23 16:12:38
Update javadoc: @return. Add @param for the param
marq (ping after 24h)
2013/10/23 16:28:49
Done.
|
| + * that a authentication token can be generated. The host must match one of the configured proxy |
| + * hosts, and the realm must be prefixed with the authentication realm string used by the data |
| + * reduction proxies. |
| + */ |
| + public boolean isAcceptableAuthChallenge(String host, String realm) { |
| + return nativeIsAcceptableAuthChallenge(mNativeDataReductionProxySettings, host, realm); |
| + } |
| + |
| + /** |
| + * Returns an authentication token for the data reduction proxy. If the token cannot be |
| + * generated, an empty string is returned. |
| + * @return The generated token. |
| + */ |
| + public String getTokenForAuthChallenge(String host, String realm) { |
|
David Trainor- moved to gerrit
2013/10/23 16:12:38
Add @param for parameters.
marq (ping after 24h)
2013/10/23 16:28:49
Done.
|
| + return nativeGetTokenForAuthChallenge(mNativeDataReductionProxySettings, host, realm); |
| + } |
| + |
| + /** |
| * Retrieves the history of daily totals of bytes that would have been |
| * received if no data reducing mechanism had been applied. |
| * @return The history of daily totals |
| @@ -183,8 +195,6 @@ public class DataReductionProxySettings { |
| int nativeDataReductionProxySettingsAndroid); |
| private native String nativeGetDataReductionProxyOrigin( |
| int nativeDataReductionProxySettingsAndroid); |
| - private native String nativeGetDataReductionProxyAuth( |
| - int nativeDataReductionProxySettingsAndroid); |
| private native boolean nativeIsDataReductionProxyEnabled( |
| int nativeDataReductionProxySettingsAndroid); |
| private native boolean nativeIsDataReductionProxyManaged( |
| @@ -195,6 +205,10 @@ public class DataReductionProxySettings { |
| int nativeDataReductionProxySettingsAndroid); |
| private native ContentLengths nativeGetContentLengths( |
| int nativeDataReductionProxySettingsAndroid); |
| + private native boolean nativeIsAcceptableAuthChallenge( |
| + int nativeDataReductionProxySettingsAndroid, String host, String realm); |
| + private native String nativeGetTokenForAuthChallenge( |
| + int nativeDataReductionProxySettingsAndroid, String host, String realm); |
| private native long[] nativeGetDailyOriginalContentLengths( |
| int nativeDataReductionProxySettingsAndroid); |
| private native long[] nativeGetDailyReceivedContentLengths( |