| OLD | NEW |
| 1 // Copyright 2014 The Chromium Authors. All rights reserved. | 1 // Copyright 2014 The Chromium Authors. All rights reserved. |
| 2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
| 3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
| 4 | 4 |
| 5 package org.chromium.net; | 5 package org.chromium.net; |
| 6 | 6 |
| 7 import android.content.Context; | 7 import android.content.Context; |
| 8 | 8 |
| 9 import java.io.IOException; | 9 import java.io.IOException; |
| 10 import java.io.PrintWriter; | 10 import java.io.PrintWriter; |
| (...skipping 20 matching lines...) Expand all Loading... |
| 31 mDefaultUserAgent = userAgent; | 31 mDefaultUserAgent = userAgent; |
| 32 } | 32 } |
| 33 | 33 |
| 34 @Override | 34 @Override |
| 35 public boolean isEnabled() { | 35 public boolean isEnabled() { |
| 36 return true; | 36 return true; |
| 37 } | 37 } |
| 38 | 38 |
| 39 @Override | 39 @Override |
| 40 public String getName() { | 40 public String getName() { |
| 41 return "HttpUrlConnection/" + Version.getVersion(); | 41 return "HttpUrlConnection/" + ApiVersion.getVersion(); |
| 42 } | 42 } |
| 43 | 43 |
| 44 @Override | 44 @Override |
| 45 public HttpUrlRequest createRequest(String url, int requestPriority, | 45 public HttpUrlRequest createRequest(String url, int requestPriority, |
| 46 Map<String, String> headers, HttpUrlRequestListener listener) { | 46 Map<String, String> headers, HttpUrlRequestListener listener) { |
| 47 return new HttpUrlConnectionUrlRequest(mContext, mDefaultUserAgent, url, | 47 return new HttpUrlConnectionUrlRequest(mContext, mDefaultUserAgent, url, |
| 48 requestPriority, headers, listener); | 48 requestPriority, headers, listener); |
| 49 } | 49 } |
| 50 | 50 |
| 51 @Override | 51 @Override |
| (...skipping 12 matching lines...) Expand all Loading... |
| 64 out.close(); | 64 out.close(); |
| 65 } catch (IOException e) { | 65 } catch (IOException e) { |
| 66 // Ignore any exceptions. | 66 // Ignore any exceptions. |
| 67 } | 67 } |
| 68 } | 68 } |
| 69 | 69 |
| 70 @Override | 70 @Override |
| 71 public void stopNetLog() { | 71 public void stopNetLog() { |
| 72 } | 72 } |
| 73 } | 73 } |
| OLD | NEW |