diff options
author | Tobrun <tobrun.van.nuland@gmail.com> | 2018-01-04 14:15:12 +0100 |
---|---|---|
committer | Tobrun <tobrun@mapbox.com> | 2018-01-09 17:05:02 +0100 |
commit | 610fb87c76b2563581a8236dbaeeecac3d198454 (patch) | |
tree | d8743dbfd8cf212a79a74a9c4247ec98255fdd84 /platform/android/MapboxGLAndroidSDK/src/main/java/com/mapbox/mapboxsdk/http/HttpRequestUtil.java | |
parent | 068d2f267f424e4e00a6dcedb323d5e6b492dd94 (diff) | |
download | qtlocation-mapboxgl-610fb87c76b2563581a8236dbaeeecac3d198454.tar.gz |
[android] - include request urls when logging out failed http requests
Diffstat (limited to 'platform/android/MapboxGLAndroidSDK/src/main/java/com/mapbox/mapboxsdk/http/HttpRequestUtil.java')
-rw-r--r-- | platform/android/MapboxGLAndroidSDK/src/main/java/com/mapbox/mapboxsdk/http/HttpRequestUtil.java | 18 |
1 files changed, 17 insertions, 1 deletions
diff --git a/platform/android/MapboxGLAndroidSDK/src/main/java/com/mapbox/mapboxsdk/http/HttpRequestUtil.java b/platform/android/MapboxGLAndroidSDK/src/main/java/com/mapbox/mapboxsdk/http/HttpRequestUtil.java index af39faeded..5afe3b6572 100644 --- a/platform/android/MapboxGLAndroidSDK/src/main/java/com/mapbox/mapboxsdk/http/HttpRequestUtil.java +++ b/platform/android/MapboxGLAndroidSDK/src/main/java/com/mapbox/mapboxsdk/http/HttpRequestUtil.java @@ -6,7 +6,7 @@ package com.mapbox.mapboxsdk.http; public class HttpRequestUtil { /** - * Set the log state of HttpRequest. + * Set the log state of HttpRequest. Default value is true. * <p> * This configuration will outlast the lifecycle of the Map. * </p> @@ -16,4 +16,20 @@ public class HttpRequestUtil { public static void setLogEnabled(boolean enabled) { HTTPRequest.enableLog(enabled); } + + /** + * Enable printing of the request url when an error occurred. Default value is false. + * <p> + * Requires {@link #setLogEnabled(boolean)} to be activated. + * </p> + * <p> + * This configuration will outlast the lifecycle of the Map. + * </p> + * + * @param enabled True will print urls, false will disable + */ + public static void setPrintRequestUrlOnFaillure(boolean enabled) { + HTTPRequest.enablePrintRequestUrlOnFailure(enabled); + } + }
\ No newline at end of file |