Chromium Code Reviews| 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.app.Application; | 7 import android.app.Application; |
| 8 import android.content.Context; | |
| 9 import android.util.Log; | |
| 10 | |
| 11 import org.chromium.base.PathUtils; | |
| 12 | 8 |
| 13 /** | 9 /** |
| 14 * Application for managing the Cronet Test. | 10 * Application for managing the Cronet Test. |
| 15 */ | 11 */ |
| 16 public class CronetTestApplication extends Application { | 12 public class CronetTestApplication extends Application { |
|
xunjieli
2015/10/29 15:55:49
Do we need an empty application?
pauljensen
2015/10/29 16:20:48
Yes, unfortunately, until we completely switch fro
xunjieli
2015/10/29 17:59:07
Acknowledged. I see.
| |
| 17 private static final String TAG = "CronetTestApplication"; | |
| 18 | |
| 19 private static final String PRIVATE_DATA_DIRECTORY_SUFFIX = "cronet_test"; | |
| 20 | |
| 21 @Override | |
| 22 public void onCreate() { | |
| 23 super.onCreate(); | |
| 24 initializeApplicationParameters(this); | |
| 25 } | |
| 26 | |
| 27 public static void initializeApplicationParameters(Context context) { | |
| 28 PathUtils.setPrivateDataDirectorySuffix(PRIVATE_DATA_DIRECTORY_SUFFIX, c ontext); | |
| 29 Log.i(TAG, "CronetTestApplication.initializeApplicationParameters()" | |
| 30 + " success."); | |
| 31 } | |
| 32 } | 13 } |
| OLD | NEW |