| The Android Open Source Project | 9066cfe | 2009-03-03 19:31:44 -0800 | [diff] [blame] | 1 | /* |
| 2 | * Copyright (C) 2008 The Android Open Source Project |
| 3 | * |
| 4 | * Licensed under the Apache License, Version 2.0 (the "License"); |
| 5 | * you may not use this file except in compliance with the License. |
| 6 | * You may obtain a copy of the License at |
| 7 | * |
| 8 | * http://www.apache.org/licenses/LICENSE-2.0 |
| 9 | * |
| 10 | * Unless required by applicable law or agreed to in writing, software |
| 11 | * distributed under the License is distributed on an "AS IS" BASIS, |
| 12 | * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. |
| 13 | * See the License for the specific language governing permissions and |
| 14 | * limitations under the License. |
| 15 | */ |
| 16 | |
| 17 | package android.test.mock; |
| 18 | |
| The Android Open Source Project | 9066cfe | 2009-03-03 19:31:44 -0800 | [diff] [blame] | 19 | import android.content.ComponentName; |
| 20 | import android.content.Intent; |
| 21 | import android.content.IntentFilter; |
| Suchi Amalapurapu | 1ccac75 | 2009-06-12 10:09:58 -0700 | [diff] [blame] | 22 | import android.content.IntentSender; |
| The Android Open Source Project | 9066cfe | 2009-03-03 19:31:44 -0800 | [diff] [blame] | 23 | import android.content.pm.ActivityInfo; |
| 24 | import android.content.pm.ApplicationInfo; |
| Anonymous Coward | ceb1b0b | 2012-04-24 10:35:16 -0700 | [diff] [blame] | 25 | import android.content.pm.ContainerEncryptionParams; |
| Dianne Hackborn | 4923734 | 2009-08-27 20:08:01 -0700 | [diff] [blame] | 26 | import android.content.pm.FeatureInfo; |
| The Android Open Source Project | 9066cfe | 2009-03-03 19:31:44 -0800 | [diff] [blame] | 27 | import android.content.pm.IPackageDataObserver; |
| Amith Yamasani | 4b2e934 | 2011-03-31 12:38:53 -0700 | [diff] [blame] | 28 | import android.content.pm.IPackageDeleteObserver; |
| The Android Open Source Project | 9066cfe | 2009-03-03 19:31:44 -0800 | [diff] [blame] | 29 | import android.content.pm.IPackageInstallObserver; |
| Suchi Amalapurapu | 8946dd3 | 2010-02-19 09:19:34 -0800 | [diff] [blame] | 30 | import android.content.pm.IPackageMoveObserver; |
| The Android Open Source Project | 9066cfe | 2009-03-03 19:31:44 -0800 | [diff] [blame] | 31 | import android.content.pm.IPackageStatsObserver; |
| 32 | import android.content.pm.InstrumentationInfo; |
| Anonymous Coward | ceb1b0b | 2012-04-24 10:35:16 -0700 | [diff] [blame] | 33 | import android.content.pm.ManifestDigest; |
| The Android Open Source Project | 9066cfe | 2009-03-03 19:31:44 -0800 | [diff] [blame] | 34 | import android.content.pm.PackageInfo; |
| 35 | import android.content.pm.PackageManager; |
| 36 | import android.content.pm.PermissionGroupInfo; |
| 37 | import android.content.pm.PermissionInfo; |
| 38 | import android.content.pm.ProviderInfo; |
| 39 | import android.content.pm.ResolveInfo; |
| 40 | import android.content.pm.ServiceInfo; |
| rich cannings | 706e8ba | 2012-08-20 13:20:14 -0700 | [diff] [blame] | 41 | import android.content.pm.VerificationParams; |
| Kenny Root | 0aaa0d9 | 2011-09-12 16:42:55 -0700 | [diff] [blame] | 42 | import android.content.pm.VerifierDeviceIdentity; |
| Amith Yamasani | 98edc95 | 2012-09-25 14:09:27 -0700 | [diff] [blame] | 43 | import android.content.pm.PackageManager.NameNotFoundException; |
| The Android Open Source Project | 9066cfe | 2009-03-03 19:31:44 -0800 | [diff] [blame] | 44 | import android.content.res.Resources; |
| 45 | import android.content.res.XmlResourceParser; |
| 46 | import android.graphics.drawable.Drawable; |
| 47 | import android.net.Uri; |
| Amith Yamasani | 655d0e2 | 2013-06-12 14:19:10 -0700 | [diff] [blame] | 48 | import android.os.Binder; |
| Christopher Tate | a2a0850d | 2013-09-05 16:38:58 -0700 | [diff] [blame] | 49 | import android.os.RemoteException; |
| Amith Yamasani | 655d0e2 | 2013-06-12 14:19:10 -0700 | [diff] [blame] | 50 | import android.os.UserHandle; |
| The Android Open Source Project | 9066cfe | 2009-03-03 19:31:44 -0800 | [diff] [blame] | 51 | |
| 52 | import java.util.List; |
| 53 | |
| 54 | /** |
| 55 | * A mock {@link android.content.pm.PackageManager} class. All methods are non-functional and throw |
| Amith Yamasani | 4b2e934 | 2011-03-31 12:38:53 -0700 | [diff] [blame] | 56 | * {@link java.lang.UnsupportedOperationException}. Override it to provide the operations that you |
| The Android Open Source Project | 9066cfe | 2009-03-03 19:31:44 -0800 | [diff] [blame] | 57 | * need. |
| 58 | */ |
| 59 | public class MockPackageManager extends PackageManager { |
| 60 | |
| 61 | @Override |
| 62 | public PackageInfo getPackageInfo(String packageName, int flags) |
| 63 | throws NameNotFoundException { |
| 64 | throw new UnsupportedOperationException(); |
| 65 | } |
| 66 | |
| 67 | @Override |
| Dianne Hackborn | 4709693 | 2010-02-11 15:57:09 -0800 | [diff] [blame] | 68 | public String[] currentToCanonicalPackageNames(String[] names) { |
| 69 | throw new UnsupportedOperationException(); |
| 70 | } |
| Amith Yamasani | 4b2e934 | 2011-03-31 12:38:53 -0700 | [diff] [blame] | 71 | |
| Dianne Hackborn | 4709693 | 2010-02-11 15:57:09 -0800 | [diff] [blame] | 72 | @Override |
| 73 | public String[] canonicalToCurrentPackageNames(String[] names) { |
| 74 | throw new UnsupportedOperationException(); |
| 75 | } |
| Amith Yamasani | 4b2e934 | 2011-03-31 12:38:53 -0700 | [diff] [blame] | 76 | |
| Dianne Hackborn | 4709693 | 2010-02-11 15:57:09 -0800 | [diff] [blame] | 77 | @Override |
| Mihai Preda | eae850c | 2009-05-13 10:13:48 +0200 | [diff] [blame] | 78 | public Intent getLaunchIntentForPackage(String packageName) { |
| The Android Open Source Project | 9066cfe | 2009-03-03 19:31:44 -0800 | [diff] [blame] | 79 | throw new UnsupportedOperationException(); |
| 80 | } |
| Mihai Preda | eae850c | 2009-05-13 10:13:48 +0200 | [diff] [blame] | 81 | |
| 82 | @Override |
| The Android Open Source Project | 9066cfe | 2009-03-03 19:31:44 -0800 | [diff] [blame] | 83 | public int[] getPackageGids(String packageName) throws NameNotFoundException { |
| 84 | throw new UnsupportedOperationException(); |
| 85 | } |
| 86 | |
| Dianne Hackborn | a06de0f | 2012-12-11 16:34:47 -0800 | [diff] [blame] | 87 | /** @hide */ |
| 88 | @Override |
| 89 | public int getPackageUid(String packageName, int userHandle) |
| 90 | throws NameNotFoundException { |
| 91 | throw new UnsupportedOperationException(); |
| 92 | } |
| 93 | |
| The Android Open Source Project | 9066cfe | 2009-03-03 19:31:44 -0800 | [diff] [blame] | 94 | @Override |
| 95 | public PermissionInfo getPermissionInfo(String name, int flags) |
| 96 | throws NameNotFoundException { |
| 97 | throw new UnsupportedOperationException(); |
| 98 | } |
| 99 | |
| 100 | @Override |
| 101 | public List<PermissionInfo> queryPermissionsByGroup(String group, int flags) |
| 102 | throws NameNotFoundException { |
| 103 | throw new UnsupportedOperationException(); |
| 104 | } |
| 105 | |
| 106 | @Override |
| 107 | public PermissionGroupInfo getPermissionGroupInfo(String name, |
| 108 | int flags) throws NameNotFoundException { |
| 109 | throw new UnsupportedOperationException(); |
| 110 | } |
| 111 | |
| 112 | @Override |
| 113 | public List<PermissionGroupInfo> getAllPermissionGroups(int flags) { |
| 114 | throw new UnsupportedOperationException(); |
| 115 | } |
| Amith Yamasani | 4b2e934 | 2011-03-31 12:38:53 -0700 | [diff] [blame] | 116 | |
| The Android Open Source Project | 9066cfe | 2009-03-03 19:31:44 -0800 | [diff] [blame] | 117 | @Override |
| 118 | public ApplicationInfo getApplicationInfo(String packageName, int flags) |
| 119 | throws NameNotFoundException { |
| 120 | throw new UnsupportedOperationException(); |
| 121 | } |
| 122 | |
| 123 | @Override |
| 124 | public ActivityInfo getActivityInfo(ComponentName className, int flags) |
| 125 | throws NameNotFoundException { |
| 126 | throw new UnsupportedOperationException(); |
| 127 | } |
| 128 | |
| 129 | @Override |
| 130 | public ActivityInfo getReceiverInfo(ComponentName className, int flags) |
| 131 | throws NameNotFoundException { |
| 132 | throw new UnsupportedOperationException(); |
| 133 | } |
| 134 | |
| 135 | @Override |
| 136 | public ServiceInfo getServiceInfo(ComponentName className, int flags) |
| 137 | throws NameNotFoundException { |
| 138 | throw new UnsupportedOperationException(); |
| 139 | } |
| 140 | |
| 141 | @Override |
| Dianne Hackborn | 361199b | 2010-08-30 17:42:07 -0700 | [diff] [blame] | 142 | public ProviderInfo getProviderInfo(ComponentName className, int flags) |
| 143 | throws NameNotFoundException { |
| 144 | throw new UnsupportedOperationException(); |
| 145 | } |
| 146 | |
| 147 | @Override |
| The Android Open Source Project | 9066cfe | 2009-03-03 19:31:44 -0800 | [diff] [blame] | 148 | public List<PackageInfo> getInstalledPackages(int flags) { |
| 149 | throw new UnsupportedOperationException(); |
| 150 | } |
| 151 | |
| Dianne Hackborn | e799175 | 2013-01-16 17:56:46 -0800 | [diff] [blame] | 152 | @Override |
| 153 | public List<PackageInfo> getPackagesHoldingPermissions(String[] permissions, |
| 154 | int flags) { |
| 155 | throw new UnsupportedOperationException(); |
| 156 | } |
| 157 | |
| Amith Yamasani | 151ec4c | 2012-09-07 19:25:16 -0700 | [diff] [blame] | 158 | /** @hide */ |
| 159 | @Override |
| 160 | public List<PackageInfo> getInstalledPackages(int flags, int userId) { |
| 161 | throw new UnsupportedOperationException(); |
| 162 | } |
| 163 | |
| The Android Open Source Project | 9066cfe | 2009-03-03 19:31:44 -0800 | [diff] [blame] | 164 | @Override |
| 165 | public int checkPermission(String permName, String pkgName) { |
| 166 | throw new UnsupportedOperationException(); |
| 167 | } |
| 168 | |
| 169 | @Override |
| 170 | public boolean addPermission(PermissionInfo info) { |
| 171 | throw new UnsupportedOperationException(); |
| 172 | } |
| 173 | |
| 174 | @Override |
| Dianne Hackborn | d7c0968 | 2010-03-30 10:42:20 -0700 | [diff] [blame] | 175 | public boolean addPermissionAsync(PermissionInfo info) { |
| 176 | throw new UnsupportedOperationException(); |
| 177 | } |
| 178 | |
| 179 | @Override |
| The Android Open Source Project | 9066cfe | 2009-03-03 19:31:44 -0800 | [diff] [blame] | 180 | public void removePermission(String name) { |
| 181 | throw new UnsupportedOperationException(); |
| 182 | } |
| 183 | |
| Dianne Hackborn | e639da7 | 2012-02-21 15:11:13 -0800 | [diff] [blame] | 184 | /** @hide */ |
| 185 | @Override |
| 186 | public void grantPermission(String packageName, String permissionName) { |
| 187 | throw new UnsupportedOperationException(); |
| 188 | } |
| 189 | |
| 190 | /** @hide */ |
| 191 | @Override |
| 192 | public void revokePermission(String packageName, String permissionName) { |
| 193 | throw new UnsupportedOperationException(); |
| 194 | } |
| 195 | |
| The Android Open Source Project | 9066cfe | 2009-03-03 19:31:44 -0800 | [diff] [blame] | 196 | @Override |
| 197 | public int checkSignatures(String pkg1, String pkg2) { |
| 198 | throw new UnsupportedOperationException(); |
| 199 | } |
| 200 | |
| 201 | @Override |
| Dianne Hackborn | 766cbfe | 2009-08-12 18:33:39 -0700 | [diff] [blame] | 202 | public int checkSignatures(int uid1, int uid2) { |
| 203 | throw new UnsupportedOperationException(); |
| 204 | } |
| 205 | |
| 206 | @Override |
| The Android Open Source Project | 9066cfe | 2009-03-03 19:31:44 -0800 | [diff] [blame] | 207 | public String[] getPackagesForUid(int uid) { |
| 208 | throw new UnsupportedOperationException(); |
| 209 | } |
| 210 | |
| 211 | @Override |
| 212 | public String getNameForUid(int uid) { |
| 213 | throw new UnsupportedOperationException(); |
| 214 | } |
| Amith Yamasani | 4b2e934 | 2011-03-31 12:38:53 -0700 | [diff] [blame] | 215 | |
| The Android Open Source Project | 9066cfe | 2009-03-03 19:31:44 -0800 | [diff] [blame] | 216 | /** |
| 217 | * @hide - to match hiding in superclass |
| 218 | */ |
| 219 | @Override |
| 220 | public int getUidForSharedUser(String sharedUserName) { |
| 221 | throw new UnsupportedOperationException(); |
| 222 | } |
| 223 | |
| 224 | @Override |
| 225 | public List<ApplicationInfo> getInstalledApplications(int flags) { |
| 226 | throw new UnsupportedOperationException(); |
| 227 | } |
| 228 | |
| 229 | @Override |
| 230 | public ResolveInfo resolveActivity(Intent intent, int flags) { |
| 231 | throw new UnsupportedOperationException(); |
| 232 | } |
| 233 | |
| Svetoslav Ganov | 58d37b5 | 2012-09-18 12:04:19 -0700 | [diff] [blame] | 234 | /** @hide */ |
| 235 | @Override |
| 236 | public ResolveInfo resolveActivityAsUser(Intent intent, int flags, int userId) { |
| 237 | throw new UnsupportedOperationException(); |
| 238 | } |
| 239 | |
| The Android Open Source Project | 9066cfe | 2009-03-03 19:31:44 -0800 | [diff] [blame] | 240 | @Override |
| 241 | public List<ResolveInfo> queryIntentActivities(Intent intent, int flags) { |
| 242 | throw new UnsupportedOperationException(); |
| 243 | } |
| 244 | |
| Amith Yamasani | 151ec4c | 2012-09-07 19:25:16 -0700 | [diff] [blame] | 245 | /** @hide */ |
| 246 | @Override |
| Svetoslav Ganov | 58d37b5 | 2012-09-18 12:04:19 -0700 | [diff] [blame] | 247 | public List<ResolveInfo> queryIntentActivitiesAsUser(Intent intent, |
| Amith Yamasani | 151ec4c | 2012-09-07 19:25:16 -0700 | [diff] [blame] | 248 | int flags, int userId) { |
| 249 | throw new UnsupportedOperationException(); |
| 250 | } |
| 251 | |
| The Android Open Source Project | 9066cfe | 2009-03-03 19:31:44 -0800 | [diff] [blame] | 252 | @Override |
| 253 | public List<ResolveInfo> queryIntentActivityOptions(ComponentName caller, |
| 254 | Intent[] specifics, Intent intent, int flags) { |
| 255 | throw new UnsupportedOperationException(); |
| 256 | } |
| 257 | |
| 258 | @Override |
| 259 | public List<ResolveInfo> queryBroadcastReceivers(Intent intent, int flags) { |
| 260 | throw new UnsupportedOperationException(); |
| 261 | } |
| 262 | |
| Amith Yamasani | f203aee | 2012-08-29 18:41:53 -0700 | [diff] [blame] | 263 | /** @hide */ |
| 264 | @Override |
| 265 | public List<ResolveInfo> queryBroadcastReceivers(Intent intent, int flags, int userId) { |
| 266 | throw new UnsupportedOperationException(); |
| 267 | } |
| 268 | |
| The Android Open Source Project | 9066cfe | 2009-03-03 19:31:44 -0800 | [diff] [blame] | 269 | @Override |
| 270 | public ResolveInfo resolveService(Intent intent, int flags) { |
| 271 | throw new UnsupportedOperationException(); |
| 272 | } |
| 273 | |
| 274 | @Override |
| 275 | public List<ResolveInfo> queryIntentServices(Intent intent, int flags) { |
| 276 | throw new UnsupportedOperationException(); |
| 277 | } |
| 278 | |
| Svetoslav Ganov | 58d37b5 | 2012-09-18 12:04:19 -0700 | [diff] [blame] | 279 | /** @hide */ |
| 280 | @Override |
| 281 | public List<ResolveInfo> queryIntentServicesAsUser(Intent intent, int flags, int userId) { |
| 282 | throw new UnsupportedOperationException(); |
| 283 | } |
| 284 | |
| Jeff Sharkey | 85f5f81 | 2013-10-07 10:16:12 -0700 | [diff] [blame] | 285 | /** @hide */ |
| 286 | @Override |
| 287 | public List<ResolveInfo> queryIntentContentProvidersAsUser( |
| 288 | Intent intent, int flags, int userId) { |
| 289 | throw new UnsupportedOperationException(); |
| 290 | } |
| 291 | |
| 292 | @Override |
| 293 | public List<ResolveInfo> queryIntentContentProviders(Intent intent, int flags) { |
| 294 | throw new UnsupportedOperationException(); |
| 295 | } |
| 296 | |
| The Android Open Source Project | 9066cfe | 2009-03-03 19:31:44 -0800 | [diff] [blame] | 297 | @Override |
| 298 | public ProviderInfo resolveContentProvider(String name, int flags) { |
| 299 | throw new UnsupportedOperationException(); |
| 300 | } |
| 301 | |
| 302 | @Override |
| 303 | public List<ProviderInfo> queryContentProviders(String processName, int uid, int flags) { |
| 304 | throw new UnsupportedOperationException(); |
| 305 | } |
| 306 | |
| 307 | @Override |
| 308 | public InstrumentationInfo getInstrumentationInfo(ComponentName className, int flags) |
| 309 | throws NameNotFoundException { |
| 310 | throw new UnsupportedOperationException(); |
| 311 | } |
| 312 | |
| 313 | @Override |
| 314 | public List<InstrumentationInfo> queryInstrumentation( |
| 315 | String targetPackage, int flags) { |
| 316 | throw new UnsupportedOperationException(); |
| 317 | } |
| 318 | |
| 319 | @Override |
| 320 | public Drawable getDrawable(String packageName, int resid, ApplicationInfo appInfo) { |
| 321 | throw new UnsupportedOperationException(); |
| 322 | } |
| 323 | |
| 324 | @Override |
| 325 | public Drawable getActivityIcon(ComponentName activityName) |
| 326 | throws NameNotFoundException { |
| 327 | throw new UnsupportedOperationException(); |
| 328 | } |
| 329 | |
| 330 | @Override |
| 331 | public Drawable getActivityIcon(Intent intent) throws NameNotFoundException { |
| 332 | throw new UnsupportedOperationException(); |
| 333 | } |
| 334 | |
| 335 | @Override |
| 336 | public Drawable getDefaultActivityIcon() { |
| 337 | throw new UnsupportedOperationException(); |
| 338 | } |
| 339 | |
| 340 | @Override |
| Jose Lima | f78e312 | 2014-03-06 12:13:15 -0800 | [diff] [blame^] | 341 | public Drawable getActivityBanner(ComponentName activityName) |
| 342 | throws NameNotFoundException { |
| 343 | throw new UnsupportedOperationException(); |
| 344 | } |
| 345 | |
| 346 | @Override |
| 347 | public Drawable getActivityBanner(Intent intent) throws NameNotFoundException { |
| 348 | throw new UnsupportedOperationException(); |
| 349 | } |
| 350 | |
| 351 | @Override |
| 352 | public Drawable getApplicationBanner(ApplicationInfo info) { |
| 353 | throw new UnsupportedOperationException(); |
| 354 | } |
| 355 | |
| 356 | @Override |
| 357 | public Drawable getApplicationBanner(String packageName) throws NameNotFoundException { |
| 358 | throw new UnsupportedOperationException(); |
| 359 | } |
| 360 | |
| 361 | @Override |
| The Android Open Source Project | 9066cfe | 2009-03-03 19:31:44 -0800 | [diff] [blame] | 362 | public Drawable getApplicationIcon(ApplicationInfo info) { |
| 363 | throw new UnsupportedOperationException(); |
| 364 | } |
| 365 | |
| 366 | @Override |
| 367 | public Drawable getApplicationIcon(String packageName) throws NameNotFoundException { |
| 368 | throw new UnsupportedOperationException(); |
| 369 | } |
| Amith Yamasani | 4b2e934 | 2011-03-31 12:38:53 -0700 | [diff] [blame] | 370 | |
| Adam Powell | 81cd2e9 | 2010-04-21 16:35:18 -0700 | [diff] [blame] | 371 | @Override |
| 372 | public Drawable getActivityLogo(ComponentName activityName) throws NameNotFoundException { |
| 373 | throw new UnsupportedOperationException(); |
| 374 | } |
| 375 | |
| 376 | @Override |
| 377 | public Drawable getActivityLogo(Intent intent) throws NameNotFoundException { |
| 378 | throw new UnsupportedOperationException(); |
| 379 | } |
| 380 | |
| 381 | @Override |
| 382 | public Drawable getApplicationLogo(ApplicationInfo info) { |
| 383 | throw new UnsupportedOperationException(); |
| 384 | } |
| 385 | |
| 386 | @Override |
| 387 | public Drawable getApplicationLogo(String packageName) throws NameNotFoundException { |
| 388 | throw new UnsupportedOperationException(); |
| 389 | } |
| The Android Open Source Project | 9066cfe | 2009-03-03 19:31:44 -0800 | [diff] [blame] | 390 | |
| 391 | @Override |
| 392 | public CharSequence getText(String packageName, int resid, ApplicationInfo appInfo) { |
| 393 | throw new UnsupportedOperationException(); |
| 394 | } |
| 395 | |
| 396 | @Override |
| 397 | public XmlResourceParser getXml(String packageName, int resid, |
| 398 | ApplicationInfo appInfo) { |
| 399 | throw new UnsupportedOperationException(); |
| 400 | } |
| 401 | |
| 402 | @Override |
| 403 | public CharSequence getApplicationLabel(ApplicationInfo info) { |
| 404 | throw new UnsupportedOperationException(); |
| 405 | } |
| 406 | |
| 407 | @Override |
| 408 | public Resources getResourcesForActivity(ComponentName activityName) |
| 409 | throws NameNotFoundException { |
| 410 | throw new UnsupportedOperationException(); |
| 411 | } |
| 412 | |
| 413 | @Override |
| 414 | public Resources getResourcesForApplication(ApplicationInfo app) { |
| 415 | throw new UnsupportedOperationException(); |
| 416 | } |
| 417 | |
| 418 | @Override |
| 419 | public Resources getResourcesForApplication(String appPackageName) |
| 420 | throws NameNotFoundException { |
| 421 | throw new UnsupportedOperationException(); |
| 422 | } |
| 423 | |
| Amith Yamasani | 98edc95 | 2012-09-25 14:09:27 -0700 | [diff] [blame] | 424 | /** @hide */ |
| 425 | @Override |
| 426 | public Resources getResourcesForApplicationAsUser(String appPackageName, int userId) { |
| 427 | throw new UnsupportedOperationException(); |
| 428 | } |
| 429 | |
| The Android Open Source Project | 9066cfe | 2009-03-03 19:31:44 -0800 | [diff] [blame] | 430 | @Override |
| 431 | public PackageInfo getPackageArchiveInfo(String archiveFilePath, int flags) { |
| 432 | throw new UnsupportedOperationException(); |
| 433 | } |
| 434 | |
| Dianne Hackborn | ade3eca | 2009-05-11 18:54:45 -0700 | [diff] [blame] | 435 | /** |
| 436 | * @hide - to match hiding in superclass |
| 437 | */ |
| The Android Open Source Project | 9066cfe | 2009-03-03 19:31:44 -0800 | [diff] [blame] | 438 | @Override |
| 439 | public void installPackage(Uri packageURI, IPackageInstallObserver observer, |
| Jacek Surazski | 65e1317 | 2009-04-28 15:26:38 +0200 | [diff] [blame] | 440 | int flags, String installerPackageName) { |
| 441 | throw new UnsupportedOperationException(); |
| 442 | } |
| Suchi Amalapurapu | 8946dd3 | 2010-02-19 09:19:34 -0800 | [diff] [blame] | 443 | |
| Dianne Hackborn | 880119b | 2010-11-18 22:26:40 -0800 | [diff] [blame] | 444 | @Override |
| 445 | public void setInstallerPackageName(String targetPackage, |
| 446 | String installerPackageName) { |
| 447 | throw new UnsupportedOperationException(); |
| 448 | } |
| 449 | |
| Suchi Amalapurapu | 8946dd3 | 2010-02-19 09:19:34 -0800 | [diff] [blame] | 450 | /** |
| 451 | * @hide - to match hiding in superclass |
| 452 | */ |
| 453 | @Override |
| 454 | public void movePackage(String packageName, IPackageMoveObserver observer, int flags) { |
| 455 | throw new UnsupportedOperationException(); |
| 456 | } |
| Amith Yamasani | 4b2e934 | 2011-03-31 12:38:53 -0700 | [diff] [blame] | 457 | |
| Jacek Surazski | 65e1317 | 2009-04-28 15:26:38 +0200 | [diff] [blame] | 458 | @Override |
| 459 | public String getInstallerPackageName(String packageName) { |
| The Android Open Source Project | 9066cfe | 2009-03-03 19:31:44 -0800 | [diff] [blame] | 460 | throw new UnsupportedOperationException(); |
| 461 | } |
| 462 | |
| 463 | /** |
| 464 | * @hide - to match hiding in superclass |
| 465 | */ |
| 466 | @Override |
| 467 | public void clearApplicationUserData( |
| 468 | String packageName, IPackageDataObserver observer) { |
| 469 | throw new UnsupportedOperationException(); |
| 470 | } |
| Amith Yamasani | 4b2e934 | 2011-03-31 12:38:53 -0700 | [diff] [blame] | 471 | |
| The Android Open Source Project | 9066cfe | 2009-03-03 19:31:44 -0800 | [diff] [blame] | 472 | /** |
| 473 | * @hide - to match hiding in superclass |
| 474 | */ |
| 475 | @Override |
| 476 | public void deleteApplicationCacheFiles( |
| 477 | String packageName, IPackageDataObserver observer) { |
| 478 | throw new UnsupportedOperationException(); |
| 479 | } |
| Amith Yamasani | 4b2e934 | 2011-03-31 12:38:53 -0700 | [diff] [blame] | 480 | |
| The Android Open Source Project | 9066cfe | 2009-03-03 19:31:44 -0800 | [diff] [blame] | 481 | /** |
| 482 | * @hide - to match hiding in superclass |
| 483 | */ |
| 484 | @Override |
| 485 | public void freeStorageAndNotify( |
| 486 | long idealStorageSize, IPackageDataObserver observer) { |
| 487 | throw new UnsupportedOperationException(); |
| 488 | } |
| The Android Open Source Project | 9066cfe | 2009-03-03 19:31:44 -0800 | [diff] [blame] | 489 | |
| 490 | /** |
| 491 | * @hide - to match hiding in superclass |
| 492 | */ |
| 493 | @Override |
| Suchi Amalapurapu | bc806f6 | 2009-06-17 15:18:19 -0700 | [diff] [blame] | 494 | public void freeStorage( |
| Suchi Amalapurapu | 1ccac75 | 2009-06-12 10:09:58 -0700 | [diff] [blame] | 495 | long idealStorageSize, IntentSender pi) { |
| 496 | throw new UnsupportedOperationException(); |
| 497 | } |
| 498 | |
| 499 | /** |
| 500 | * @hide - to match hiding in superclass |
| 501 | */ |
| 502 | @Override |
| The Android Open Source Project | 9066cfe | 2009-03-03 19:31:44 -0800 | [diff] [blame] | 503 | public void deletePackage( |
| 504 | String packageName, IPackageDeleteObserver observer, int flags) { |
| 505 | throw new UnsupportedOperationException(); |
| 506 | } |
| 507 | |
| 508 | @Override |
| 509 | public void addPackageToPreferred(String packageName) { |
| 510 | throw new UnsupportedOperationException(); |
| 511 | } |
| 512 | |
| 513 | @Override |
| 514 | public void removePackageFromPreferred(String packageName) { |
| 515 | throw new UnsupportedOperationException(); |
| 516 | } |
| 517 | |
| 518 | @Override |
| 519 | public List<PackageInfo> getPreferredPackages(int flags) { |
| 520 | throw new UnsupportedOperationException(); |
| 521 | } |
| 522 | |
| 523 | @Override |
| 524 | public void setComponentEnabledSetting(ComponentName componentName, |
| 525 | int newState, int flags) { |
| 526 | throw new UnsupportedOperationException(); |
| 527 | } |
| 528 | |
| 529 | @Override |
| 530 | public int getComponentEnabledSetting(ComponentName componentName) { |
| 531 | throw new UnsupportedOperationException(); |
| 532 | } |
| 533 | |
| 534 | @Override |
| 535 | public void setApplicationEnabledSetting(String packageName, int newState, int flags) { |
| 536 | throw new UnsupportedOperationException(); |
| 537 | } |
| Amith Yamasani | 4b2e934 | 2011-03-31 12:38:53 -0700 | [diff] [blame] | 538 | |
| The Android Open Source Project | 9066cfe | 2009-03-03 19:31:44 -0800 | [diff] [blame] | 539 | @Override |
| 540 | public int getApplicationEnabledSetting(String packageName) { |
| 541 | throw new UnsupportedOperationException(); |
| 542 | } |
| 543 | |
| 544 | @Override |
| 545 | public void addPreferredActivity(IntentFilter filter, |
| 546 | int match, ComponentName[] set, ComponentName activity) { |
| 547 | throw new UnsupportedOperationException(); |
| 548 | } |
| Amith Yamasani | 4b2e934 | 2011-03-31 12:38:53 -0700 | [diff] [blame] | 549 | |
| Satish Sampath | 8dbe612 | 2009-06-02 23:35:54 +0100 | [diff] [blame] | 550 | /** |
| 551 | * @hide - to match hiding in superclass |
| 552 | */ |
| 553 | @Override |
| 554 | public void replacePreferredActivity(IntentFilter filter, |
| 555 | int match, ComponentName[] set, ComponentName activity) { |
| 556 | throw new UnsupportedOperationException(); |
| 557 | } |
| 558 | |
| 559 | |
| The Android Open Source Project | 9066cfe | 2009-03-03 19:31:44 -0800 | [diff] [blame] | 560 | @Override |
| 561 | public void clearPackagePreferredActivities(String packageName) { |
| 562 | throw new UnsupportedOperationException(); |
| 563 | } |
| 564 | |
| 565 | /** |
| 566 | * @hide - to match hiding in superclass |
| 567 | */ |
| 568 | @Override |
| Dianne Hackborn | 0c38049 | 2012-08-20 17:23:30 -0700 | [diff] [blame] | 569 | public void getPackageSizeInfo(String packageName, int userHandle, |
| 570 | IPackageStatsObserver observer) { |
| The Android Open Source Project | 9066cfe | 2009-03-03 19:31:44 -0800 | [diff] [blame] | 571 | throw new UnsupportedOperationException(); |
| 572 | } |
| 573 | |
| 574 | @Override |
| The Android Open Source Project | 9066cfe | 2009-03-03 19:31:44 -0800 | [diff] [blame] | 575 | public int getPreferredActivities(List<IntentFilter> outFilters, |
| 576 | List<ComponentName> outActivities, String packageName) { |
| 577 | throw new UnsupportedOperationException(); |
| 578 | } |
| Amith Yamasani | 4b2e934 | 2011-03-31 12:38:53 -0700 | [diff] [blame] | 579 | |
| Christopher Tate | a2a0850d | 2013-09-05 16:38:58 -0700 | [diff] [blame] | 580 | /** @hide - hidden in superclass */ |
| 581 | @Override |
| 582 | public ComponentName getHomeActivities(List<ResolveInfo> outActivities) { |
| 583 | throw new UnsupportedOperationException(); |
| 584 | } |
| 585 | |
| The Android Open Source Project | 9066cfe | 2009-03-03 19:31:44 -0800 | [diff] [blame] | 586 | @Override |
| 587 | public String[] getSystemSharedLibraryNames() { |
| 588 | throw new UnsupportedOperationException(); |
| 589 | } |
| Amith Yamasani | 4b2e934 | 2011-03-31 12:38:53 -0700 | [diff] [blame] | 590 | |
| The Android Open Source Project | 9066cfe | 2009-03-03 19:31:44 -0800 | [diff] [blame] | 591 | @Override |
| Dianne Hackborn | 4923734 | 2009-08-27 20:08:01 -0700 | [diff] [blame] | 592 | public FeatureInfo[] getSystemAvailableFeatures() { |
| 593 | throw new UnsupportedOperationException(); |
| 594 | } |
| Amith Yamasani | 4b2e934 | 2011-03-31 12:38:53 -0700 | [diff] [blame] | 595 | |
| Dianne Hackborn | 4923734 | 2009-08-27 20:08:01 -0700 | [diff] [blame] | 596 | @Override |
| Dianne Hackborn | 039c68e | 2009-09-26 16:39:23 -0700 | [diff] [blame] | 597 | public boolean hasSystemFeature(String name) { |
| 598 | throw new UnsupportedOperationException(); |
| 599 | } |
| Amith Yamasani | 4b2e934 | 2011-03-31 12:38:53 -0700 | [diff] [blame] | 600 | |
| Dianne Hackborn | 039c68e | 2009-09-26 16:39:23 -0700 | [diff] [blame] | 601 | @Override |
| The Android Open Source Project | 9066cfe | 2009-03-03 19:31:44 -0800 | [diff] [blame] | 602 | public boolean isSafeMode() { |
| 603 | throw new UnsupportedOperationException(); |
| 604 | } |
| Amith Yamasani | 4b2e934 | 2011-03-31 12:38:53 -0700 | [diff] [blame] | 605 | |
| 606 | /** |
| 607 | * @hide |
| 608 | */ |
| 609 | @Override |
| Kenny Root | 5ab2157 | 2011-07-27 11:11:19 -0700 | [diff] [blame] | 610 | public void installPackageWithVerification(Uri packageURI, IPackageInstallObserver observer, |
| 611 | int flags, String installerPackageName, Uri verificationURI, |
| Rich Cannings | e1d7c71 | 2012-08-08 12:46:06 -0700 | [diff] [blame] | 612 | ManifestDigest manifestDigest, ContainerEncryptionParams encryptionParams) { |
| Kenny Root | 5ab2157 | 2011-07-27 11:11:19 -0700 | [diff] [blame] | 613 | throw new UnsupportedOperationException(); |
| 614 | } |
| 615 | |
| rich cannings | 706e8ba | 2012-08-20 13:20:14 -0700 | [diff] [blame] | 616 | /** |
| 617 | * @hide |
| 618 | */ |
| 619 | @Override |
| 620 | public void installPackageWithVerificationAndEncryption(Uri packageURI, |
| 621 | IPackageInstallObserver observer, int flags, String installerPackageName, |
| 622 | VerificationParams verificationParams, ContainerEncryptionParams encryptionParams) { |
| 623 | throw new UnsupportedOperationException(); |
| 624 | } |
| 625 | |
| Dianne Hackborn | 7767eac | 2012-08-23 18:25:40 -0700 | [diff] [blame] | 626 | /** |
| 627 | * @hide |
| 628 | */ |
| 629 | @Override |
| Amith Yamasani | 655d0e2 | 2013-06-12 14:19:10 -0700 | [diff] [blame] | 630 | public boolean setApplicationBlockedSettingAsUser(String packageName, boolean blocked, |
| 631 | UserHandle user) { |
| 632 | return false; |
| 633 | } |
| 634 | |
| 635 | /** |
| 636 | * @hide |
| 637 | */ |
| 638 | @Override |
| 639 | public boolean getApplicationBlockedSettingAsUser(String packageName, UserHandle user) { |
| 640 | return false; |
| 641 | } |
| 642 | |
| 643 | /** |
| 644 | * @hide |
| 645 | */ |
| 646 | @Override |
| Dianne Hackborn | 7767eac | 2012-08-23 18:25:40 -0700 | [diff] [blame] | 647 | public int installExistingPackage(String packageName) |
| 648 | throws NameNotFoundException { |
| 649 | throw new UnsupportedOperationException(); |
| 650 | } |
| 651 | |
| Kenny Root | 5ab2157 | 2011-07-27 11:11:19 -0700 | [diff] [blame] | 652 | @Override |
| Kenny Root | 3a9b5fb | 2011-09-20 14:15:38 -0700 | [diff] [blame] | 653 | public void verifyPendingInstall(int id, int verificationCode) { |
| Kenny Root | 5ab2157 | 2011-07-27 11:11:19 -0700 | [diff] [blame] | 654 | throw new UnsupportedOperationException(); |
| 655 | } |
| Kenny Root | 0aaa0d9 | 2011-09-12 16:42:55 -0700 | [diff] [blame] | 656 | |
| rich cannings | d9ef3e5 | 2012-08-22 14:28:05 -0700 | [diff] [blame] | 657 | @Override |
| 658 | public void extendVerificationTimeout(int id, int verificationCodeAtTimeout, |
| 659 | long millisecondsToDelay) { |
| 660 | throw new UnsupportedOperationException(); |
| 661 | } |
| 662 | |
| Kenny Root | 0aaa0d9 | 2011-09-12 16:42:55 -0700 | [diff] [blame] | 663 | /** |
| 664 | * @hide |
| 665 | */ |
| 666 | @Override |
| 667 | public VerifierDeviceIdentity getVerifierDeviceIdentity() { |
| 668 | throw new UnsupportedOperationException(); |
| 669 | } |
| The Android Open Source Project | 9066cfe | 2009-03-03 19:31:44 -0800 | [diff] [blame] | 670 | } |