1<!DOCTYPE html> 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99<html> 100<head> 101 102 103<meta http-equiv="Content-Type" content="text/html; charset=utf-8" /> 104<meta name="viewport" content="width=device-width" /> 105 106<link rel="shortcut icon" type="image/x-icon" href="/favicon.ico" /> 107<title>ConnectionResult | Android Developers</title> 108 109<!-- STYLESHEETS --> 110<link rel="stylesheet" 111href="//fonts.googleapis.com/css?family=Roboto+Condensed"> 112<link rel="stylesheet" href="//fonts.googleapis.com/css?family=Roboto:light,regular,medium,thin,italic,mediumitalic,bold" 113 title="roboto"> 114<link href="/assets/css/default.css?v=4" rel="stylesheet" type="text/css"> 115 116 117 118<!-- JAVASCRIPT --> 119<script src="//www.google.com/jsapi" type="text/javascript"></script> 120<script src="/assets/js/android_3p-bundle.js" type="text/javascript"></script> 121<script type="text/javascript"> 122 var toRoot = "/"; 123 var metaTags = []; 124 var devsite = false; 125</script> 126<script src="/assets/js/docs.js?v=3" type="text/javascript"></script> 127 128 129 130<script> 131 (function(i,s,o,g,r,a,m){i['GoogleAnalyticsObject']=r;i[r]=i[r]||function(){ 132 (i[r].q=i[r].q||[]).push(arguments)},i[r].l=1*new Date();a=s.createElement(o), 133 m=s.getElementsByTagName(o)[0];a.async=1;a.src=g;m.parentNode.insertBefore(a,m) 134 })(window,document,'script','//www.google-analytics.com/analytics.js','ga'); 135 136 ga('create', 'UA-5831155-1', 'android.com'); 137 ga('create', 'UA-49880327-2', 'android.com', {'name': 'universal'}); // New tracker); 138 ga('send', 'pageview'); 139 ga('universal.send', 'pageview'); // Send page view for new tracker. 140</script> 141 142</head> 143 144<body class="gc-documentation google 145 develop reference" itemscope itemtype="http://schema.org/Article"> 146 <div id="doc-api-level" class="" style="display:none"></div> 147 <a name="top"></a> 148 149 150<a name="top"></a> 151 152<!-- dialog to prompt lang pref change when loaded from hardcoded URL 153<div id="langMessage" style="display:none"> 154 <div> 155 <div class="lang en"> 156 <p>You requested a page in English, would you like to proceed with this language setting?</p> 157 </div> 158 <div class="lang es"> 159 <p>You requested a page in Spanish (Español), would you like to proceed with this language setting?</p> 160 </div> 161 <div class="lang ja"> 162 <p>You requested a page in Japanese (日本語), would you like to proceed with this language setting?</p> 163 </div> 164 <div class="lang ko"> 165 <p>You requested a page in Korean (한국어), would you like to proceed with this language setting?</p> 166 </div> 167 <div class="lang ru"> 168 <p>You requested a page in Russian (Русский), would you like to proceed with this language setting?</p> 169 </div> 170 <div class="lang zh-cn"> 171 <p>You requested a page in Simplified Chinese (简体中文), would you like to proceed with this language setting?</p> 172 </div> 173 <div class="lang zh-tw"> 174 <p>You requested a page in Traditional Chinese (繁體中文), would you like to proceed with this language setting?</p> 175 </div> 176 <a href="#" class="button yes" onclick="return false;"> 177 <span class="lang en">Yes</span> 178 <span class="lang es">Sí</span> 179 <span class="lang ja">Yes</span> 180 <span class="lang ko">Yes</span> 181 <span class="lang ru">Yes</span> 182 <span class="lang zh-cn">是的</span> 183 <span class="lang zh-tw">没有</span> 184 </a> 185 <a href="#" class="button" onclick="$('#langMessage').hide();return false;"> 186 <span class="lang en">No</span> 187 <span class="lang es">No</span> 188 <span class="lang ja">No</span> 189 <span class="lang ko">No</span> 190 <span class="lang ru">No</span> 191 <span class="lang zh-cn">没有</span> 192 <span class="lang zh-tw">没有</span> 193 </a> 194 </div> 195</div> --> 196 197 198 <!-- Header --> 199 <div id="header-wrapper"> 200 <div id="header"> 201 202 203 204 205 <div class="wrap" id="header-wrap"> 206 <div class="col-3 logo"> 207 <a href="/index.html"> 208 <img src="/assets/images/dac_logo.png" 209 srcset="/assets/images/dac_logo@2x.png 2x" 210 width="123" height="25" alt="Android Developers" /> 211 </a> 212 <div class="btn-quicknav" id="btn-quicknav"> 213 <a href="#" class="arrow-inactive">Quicknav</a> 214 <a href="#" class="arrow-active">Quicknav</a> 215 </div> 216 </div> 217 <ul class="nav-x col-9"> 218 <li class="design"> 219 <a href="/design/index.html" 220 zh-tw-lang="設計" 221 zh-cn-lang="设计" 222 ru-lang="Проектирование" 223 ko-lang="디자인" 224 ja-lang="設計" 225 es-lang="Diseñar" 226 >Design</a></li> 227 <li class="develop"><a href="/develop/index.html" 228 zh-tw-lang="開發" 229 zh-cn-lang="开发" 230 ru-lang="Разработка" 231 ko-lang="개발" 232 ja-lang="開発" 233 es-lang="Desarrollar" 234 >Develop</a></li> 235 <li class="distribute last"><a href="/distribute/index.html" 236 zh-tw-lang="發佈" 237 zh-cn-lang="分发" 238 ru-lang="Распространение" 239 ko-lang="배포" 240 ja-lang="配布" 241 es-lang="Distribuir" 242 >Distribute</a></li> 243 </ul> 244 245 246 247 248<div class="menu-container"> 249 <div class="moremenu"> 250 <div id="more-btn"></div> 251 </div> 252 <div class="morehover" id="moremenu"> 253 <div class="top"></div> 254 <div class="mid"> 255 <div class="header">Links</div> 256 <ul> 257 <li><a href="https://play.google.com/apps/publish/" target="_googleplay">Google Play Developer Console</a></li> 258 <li><a href="http://android-developers.blogspot.com/">Android Developers Blog</a></li> 259 <li><a href="/about/index.html">About Android</a></li> 260 </ul> 261 <div class="header">Android Sites</div> 262 <ul> 263 <li><a href="http://www.android.com">Android.com</a></li> 264 <li class="active"><a>Android Developers</a></li> 265 <li><a href="http://source.android.com">Android Open Source Project</a></li> 266 </ul> 267 268 269 270 <div class="header">Language</div> 271 <div id="language" class="locales"> 272 <select name="language" onChange="changeLangPref(this.value, true)"> 273 <option value="en">English</option> 274 <option value="es">Español</option> 275 <option value="ja">日本語</option> 276 <option value="ko">한국어</option> 277 <option value="ru">Русский</option> 278 <option value="zh-cn">中文(简体)</option> 279 <option value="zh-tw">中文(繁體)</option> 280 </select> 281 </div> 282 <script type="text/javascript"> 283 <!-- 284 loadLangPref(); 285 //--> 286 </script> 287 288 289 <br class="clearfix" /> 290 </div><!-- end 'mid' --> 291 <div class="bottom"></div> 292 </div><!-- end 'moremenu' --> 293 294 <div class="search" id="search-container"> 295 <div class="search-inner"> 296 <div id="search-btn"></div> 297 <div class="left"></div> 298 <form onsubmit="return submit_search()"> 299 <input id="search_autocomplete" type="text" value="" autocomplete="off" name="q" 300 onfocus="search_focus_changed(this, true)" onblur="search_focus_changed(this, false)" 301 onkeydown="return search_changed(event, true, '/')" 302 onkeyup="return search_changed(event, false, '/')" /> 303 </form> 304 <div class="right"></div> 305 <a class="close hide">close</a> 306 <div class="left"></div> 307 <div class="right"></div> 308 </div><!-- end search-inner --> 309 </div><!-- end search-container --> 310 311 <div class="search_filtered_wrapper reference"> 312 <div class="suggest-card reference no-display"> 313 <ul class="search_filtered"> 314 </ul> 315 </div> 316 </div> 317 318 <div class="search_filtered_wrapper docs"> 319 <div class="suggest-card dummy no-display"> </div> 320 <div class="suggest-card develop no-display"> 321 <ul class="search_filtered"> 322 </ul> 323 <div class="child-card guides no-display"> 324 </div> 325 <div class="child-card training no-display"> 326 </div> 327 <div class="child-card samples no-display"> 328 </div> 329 </div> 330 <div class="suggest-card design no-display"> 331 <ul class="search_filtered"> 332 </ul> 333 </div> 334 <div class="suggest-card distribute no-display"> 335 <ul class="search_filtered"> 336 </ul> 337 </div> 338 </div> 339</div><!-- end menu-container (search and menu widget) --> 340 341 342 343 <!-- Expanded quicknav --> 344 <div id="quicknav" class="col-13"> 345 <ul> 346 <li class="about"> 347 <ul> 348 <li><a href="/about/index.html">About</a></li> 349 <li><a href="/wear/index.html">Wear</a></li> 350 <li><a href="/tv/index.html">TV</a></li> 351 <li><a href="/auto/index.html">Auto</a></li> 352 </ul> 353 </li> 354 <li class="design"> 355 <ul> 356 <li><a href="/design/index.html">Get Started</a></li> 357 <li><a href="/design/devices.html">Devices</a></li> 358 <li><a href="/design/style/index.html">Style</a></li> 359 <li><a href="/design/patterns/index.html">Patterns</a></li> 360 <li><a href="/design/building-blocks/index.html">Building Blocks</a></li> 361 <li><a href="/design/downloads/index.html">Downloads</a></li> 362 <li><a href="/design/videos/index.html">Videos</a></li> 363 </ul> 364 </li> 365 <li class="develop"> 366 <ul> 367 <li><a href="/training/index.html" 368 zh-tw-lang="訓練課程" 369 zh-cn-lang="培训" 370 ru-lang="Курсы" 371 ko-lang="교육" 372 ja-lang="トレーニング" 373 es-lang="Capacitación" 374 >Training</a></li> 375 <li><a href="/guide/index.html" 376 zh-tw-lang="API 指南" 377 zh-cn-lang="API 指南" 378 ru-lang="Руководства по API" 379 ko-lang="API 가이드" 380 ja-lang="API ガイド" 381 es-lang="Guías de la API" 382 >API Guides</a></li> 383 <li><a href="/reference/packages.html" 384 zh-tw-lang="參考資源" 385 zh-cn-lang="参考" 386 ru-lang="Справочник" 387 ko-lang="참조문서" 388 ja-lang="リファレンス" 389 es-lang="Referencia" 390 >Reference</a></li> 391 <li><a href="/sdk/index.html" 392 zh-tw-lang="相關工具" 393 zh-cn-lang="工具" 394 ru-lang="Инструменты" 395 ko-lang="도구" 396 ja-lang="ツール" 397 es-lang="Herramientas" 398 >Tools</a> 399 </li> 400 <li><a href="/google/index.html">Google Services</a> 401 </li> 402 403 <li><a href="/samples/index.html">Samples</a> 404 </li> 405 406 </ul> 407 </li> 408 <li class="distribute last"> 409 <ul> 410 <li><a href="/distribute/googleplay/index.html">Google Play</a></li> 411 <li><a href="/distribute/essentials/index.html">Essentials</a></li> 412 <li><a href="/distribute/users/index.html">Get Users</a></li> 413 <li><a href="/distribute/engage/index.html">Engage & Retain</a></li> 414 <li><a href="/distribute/monetize/index.html">Monetize</a></li> 415 <li><a href="/distribute/tools/index.html">Tools & Reference</a></li> 416 <li><a href="/distribute/stories/index.html">Developer Stories</a></li> 417 </ul> 418 </li> 419 </ul> 420 </div><!-- /Expanded quicknav --> 421 </div><!-- end header-wrap.wrap --> 422 </div><!-- end header --> 423 424 425 <!-- Secondary x-nav --> 426 <div id="nav-x"> 427 <div class="wrap" style="position:relative;z-index:1"> 428 429 430 431 432 433 <ul class="nav-x col-9 develop" style="width:100%"> 434 <li class="training"><a href="/training/index.html" 435 zh-tw-lang="訓練課程" 436 zh-cn-lang="培训" 437 ru-lang="Курсы" 438 ko-lang="교육" 439 ja-lang="トレーニング" 440 es-lang="Capacitación" 441 >Training</a></li> 442 <li class="guide"><a href="/guide/index.html" 443 zh-tw-lang="API 指南" 444 zh-cn-lang="API 指南" 445 ru-lang="Руководства по API" 446 ko-lang="API 가이드" 447 ja-lang="API ガイド" 448 es-lang="Guías de la API" 449 >API Guides</a></li> 450 <li class="reference"><a href="/reference/packages.html" 451 zh-tw-lang="參考資源" 452 zh-cn-lang="参考" 453 ru-lang="Справочник" 454 ko-lang="참조문서" 455 ja-lang="リファレンス" 456 es-lang="Referencia" 457 >Reference</a></li> 458 <li class="tools"><a href="/sdk/index.html" 459 zh-tw-lang="相關工具" 460 zh-cn-lang="工具" 461 ru-lang="Инструменты" 462 ko-lang="도구" 463 ja-lang="ツール" 464 es-lang="Herramientas" 465 >Tools</a></li> 466 <li class="google"><a href="/google/index.html" 467 >Google Services</a> 468 </li> 469 470 <li class="samples"><a href="/samples/index.html" 471 >Samples</a> 472 </li> 473 474 </ul> 475 </div> 476 </div> 477 <!-- /Sendondary x-nav DEVELOP --> 478 479 480 481 <div id="searchResults" class="wrap" style="display:none;"> 482 <h2 id="searchTitle">Results</h2> 483 <div id="leftSearchControl" class="search-control">Loading...</div> 484 </div> 485 </div> <!--end header-wrapper --> 486 487 <div id="sticky-header"> 488 <div> 489 <a class="logo" href="#top"></a> 490 <a class="top" href="#top"></a> 491 <ul class="breadcrumb"> 492 493 <li class="current">ConnectionResult</li> 494 </ul> 495 </div> 496 </div> 497 498 499 500 501 502 503 <div class="wrap clearfix" id="body-content"> 504 <div class="col-4" id="side-nav" itemscope itemtype="http://schema.org/SiteNavigationElement"> 505 <div id="devdoc-nav" class="scroll-pane"> 506 507 508 509<ul id="nav"> 510 511 <li class="nav-section"> 512 <div class="nav-section-header empty"><a href="/google/index.html"> 513 <span class="en">Overview</span> 514 </a></div> 515 </li> 516 517 <li class="nav-section"> 518 <div class="nav-section-header empty"><a href="/google/play-services/games.html"> 519 <span class="en">Games</span> 520 </a></div> 521 </li> 522 <li class="nav-section"> 523 <div class="nav-section-header empty"><a href="/google/play-services/location.html"> 524 <span class="en">Location</span> 525 </a></div> 526 </li> 527 <li class="nav-section"> 528 <div class="nav-section-header empty"><a href="/google/play-services/plus.html"> 529 <span class="en">Google+</span> 530 </a></div> 531 </li> 532 <li class="nav-section"> 533 <div class="nav-section-header empty"><a href="/google/play-services/maps.html"> 534 <span class="en">Maps</span> 535 </a></div> 536 </li> 537 <li class="nav-section"> 538 <div class="nav-section-header empty"><a href="/google/play-services/drive.html"> 539 <span class="en">Drive</span> 540 </a></div> 541 </li> 542 <li class="nav-section"> 543 <div class="nav-section-header empty"><a href="/google/play-services/cast.html"> 544 <span class="en">Cast</span> 545 </a></div> 546 </li> 547 <li class="nav-section"> 548 <div class="nav-section-header"><a href="/google/play-services/ads.html"> 549 <span class="en">Ads</span></a> 550 </div> 551 <ul> 552 <li><a href="/google/play-services/id.html"> 553 <span class="en">Advertising ID</span></a> 554 </li> 555 </ul> 556 </li> 557 <li class="nav-section"> 558 <div class="nav-section-header empty"><a href="/google/play-services/wallet.html"> 559 <span class="en">Wallet</span> 560 </a></div> 561 </li> 562 563 564 <li class="nav-section"> 565 <div class="nav-section-header"><a href="/google/play-services/index.html"> 566 <span class="en">Google Play Services</span></a> 567 </div> 568 <ul> 569 <li><a href="/google/play-services/setup.html"> 570 <span class="en">Setting Up Google Play Services</span></a> 571 </li> 572 <li class="nav-section"> 573 <div class="nav-section-header"><a href="/google/auth/api-client.html"> 574 <span class="en">Accessing Google APIs</span></a> 575 </div> 576 <ul> 577 <li> 578 <a href="/google/auth/http-auth.html"> 579 <span class="en">Authorizing with Google for REST APIs</span> 580 </a> 581 </li> 582 </ul> 583 </li> 584 <li id="gms-tree-list" class="nav-section"> 585 <div class="nav-section-header"> 586 <a href="/reference/gms-packages.html"> 587 <span class="en">Reference</span> 588 </a> 589 <div> 590 </li> 591 </ul> 592 </li> 593 594 595 <li class="nav-section"> 596 <div class="nav-section-header"><a href="/google/play/billing/index.html"> 597 <span class="en">Google Play In-app Billing</span></a> 598 </div> 599 <ul> 600 <li><a href="/google/play/billing/billing_overview.html"> 601 <span class="en">Overview</span></a> 602 </li> 603 <li class="nav-section"><div class="nav-section-header"><a href="/google/play/billing/api.html"> 604 <span class="en">Version 3 API</span></a></div> 605 <ul> 606 <li><a href="/google/play/billing/billing_integrate.html"> 607 <span class="en">Implementing the API</span></a></li> 608 <li><a href="/google/play/billing/billing_reference.html"> 609 <span class="en">Reference</span></a></li> 610 </ul> 611 </li> 612 <li class="nav-section"><div class="nav-section-header"><a href="/google/play/billing/v2/api.html"> 613 <span class="en">Version 2 API</span></a></div> 614 <ul> 615 <li><a href="/google/play/billing/v2/billing_integrate.html"> 616 <span class="en">Implementing the API</span></a></li> 617 <li><a href="/google/play/billing/v2/billing_subscriptions.html"> 618 <span class="en">Subscriptions</span></a></li> 619 <li><a href="/google/play/billing/v2/billing_reference.html"> 620 <span class="en">Reference</span></a></li> 621 </ul> 622 </li> 623 <li><a href="/google/play/billing/billing_subscriptions.html"> 624 <span class="en">Subscriptions</span></a> 625 </li> 626 <li><a href="/google/play/billing/billing_best_practices.html"> 627 <span class="en">Security and Design</span></a> 628 </li> 629 <li><a href="/google/play/billing/billing_testing.html"> 630 <span class="en">Testing In-app Billing</span></a> 631 </li> 632 <li><a href="/google/play/billing/billing_admin.html"> 633 <span class="en">Administering In-app Billing</span></a> 634 </li> 635 <li><a href="/google/play/billing/versions.html"> 636 <span class="en">Version Notes</span></a> 637 </li> 638 </ul> 639 </li> 640 641 642 643 <li class="nav-section"> 644 <div class="nav-section-header"><a href="/google/gcm/index.html"> 645 <span class="en">Google Cloud Messaging</span></a> 646 </div> 647 <ul> 648 <li><a href="/google/gcm/gcm.html"> 649 <span class="en">Overview</span></a> 650 </li> 651 <li><a href="/google/gcm/gs.html"> 652 <span class="en">Getting Started</span></a> 653 </li> 654 <li><a href="/google/gcm/client.html"> 655 <span class="en">Implementing GCM Client</span></a> 656 </li> 657 <li class="nav-section"><div class="nav-section-header"><a href="/google/gcm/server.html"> 658 <span class="en">Implementing GCM Server</span></a></div> 659 <ul> 660 <li><a href="/google/gcm/ccs.html"> 661 <span class="en">CCS (XMPP)</span></a></li> 662 <li><a href="/google/gcm/http.html"> 663 <span class="en">HTTP</span></a></li> 664 </ul> 665 </li> 666 <li><a href="/google/gcm/notifications.html"> 667 <span class="en">User Notifications</span></a> 668 </li> 669 <li><a href="/google/gcm/adv.html"> 670 <span class="en">Advanced Topics</span></a> 671 </li> 672 <li><a href="/google/gcm/c2dm.html"> 673 <span class="en">Migration</span></a> 674 </li> 675 <li id="gcm-tree-list" class="nav-section"> 676 <div class="nav-section-header"> 677 <a href="/reference/gcm-packages.html"> 678 <span class="en">Reference</span> 679 </a> 680 <div> 681 </li> 682 </ul> 683 </li> 684 685 <li class="nav-section"> 686 <div class="nav-section-header empty"><a href="/google/gcs/index.html"> 687 <span class="en">Google Cloud Save</span></a> 688 </div> 689 </li> 690 691 <li class="nav-section"> 692 <div class="nav-section-header"><a href="/google/play/dist.html"> 693 <span class="en">Google Play Distribution</span></a> 694 </div> 695 <ul> 696 <li><a href="/google/play/filters.html"> 697 <span class="en">Filters on Google Play</span></a> 698 </li> 699 <li><a href="/google/play/billing/gp-purchase-status-api.html"> 700 <span class="en">Google Play Developer API</span></a> 701 </li> 702 <li><a href="/google/play/publishing/multiple-apks.html"> 703 <span class="en">Multiple APK Support</span></a> 704 </li> 705 <li><a href="/google/play/expansion-files.html"> 706 <span class="en">APK Expansion Files</span></a> 707 </li> 708 <li class="nav-section"> 709 <div class="nav-section-header"><a href="/google/play/licensing/index.html"> 710 <span class="en">Application Licensing</span></a> 711 </div> 712 <ul> 713 <li><a href="/google/play/licensing/overview.html"> 714 <span class="en">Licensing Overview</span></a> 715 </li> 716 <li><a href="/google/play/licensing/setting-up.html"> 717 <span class="en">Setting Up for Licensing</span></a> 718 </li> 719 <li><a href="/google/play/licensing/adding-licensing.html"> 720 <span class="en">Adding Licensing to Your App</span></a> 721 </li> 722 <li><a href="/google/play/licensing/licensing-reference.html"> 723 <span class="en">Licensing Reference</span></a> 724 </li> 725 </ul> 726 </li> 727 728 <li class="nav-section"> 729 <div class="nav-section-header"><a href="/google/backup/index.html"> 730 Android Backup Service</a> 731 </div> 732 <ul> 733 <li><a href="/google/backup/signup.html"> 734 Register</a> 735 </li> 736 </ul> 737 </li> 738 739 </ul> 740 741</li> 742 743 744 745</ul> 746 747<script type="text/javascript"> 748<!-- 749 buildToggleLists(); 750 changeNavLang(getLangPref()); 751//--> 752</script> 753 754 755 756 757 </div> 758 <script type="text/javascript"> 759 showGoogleRefTree(); 760 761 </script> 762 </div> <!-- end side-nav --> 763 <script> 764 $(document).ready(function() { 765 scrollIntoView("devdoc-nav"); 766 }); 767 </script> 768 769 770 771 772 773 774<div class="col-12" id="doc-col"> 775 776<div id="api-info-block"> 777 778 779 780 781 782 783 784 785 786 787 788<div class="sum-details-links"> 789 790Summary: 791 792 793 794 795 796 <a href="#constants">Constants</a> 797 798 799 800 801 802 803 | <a href="#pubctors">Ctors</a> 804 805 806 807 808 | <a href="#pubmethods">Methods</a> 809 810 811 812 813 | <a href="#inhmethods">Inherited Methods</a> 814 815| <a href="#" onclick="return toggleAllClassInherited()" id="toggleAllClassInherited">[Expand All]</a> 816 817</div><!-- end sum-details-links --> 818<div class="api-level"> 819 820 821 822 823</div> 824</div><!-- end api-info-block --> 825 826 827<!-- ======== START OF CLASS DATA ======== --> 828 829<div id="jd-header"> 830 public 831 832 final 833 834 class 835<h1 itemprop="name">ConnectionResult</h1> 836 837 838 839 840 extends Object<br/> 841 842 843 844 845 846 847 848 849 850 851 852 853</div><!-- end header --> 854 855<div id="naMessage"></div> 856 857<div id="jd-content" class="api apilevel-"> 858<table class="jd-inheritance-table"> 859 860 861 <tr> 862 863 <td colspan="2" class="jd-inheritance-class-cell">java.lang.Object</td> 864 </tr> 865 866 867 <tr> 868 869 <td class="jd-inheritance-space"> ↳</td> 870 871 <td colspan="1" class="jd-inheritance-class-cell">com.google.android.gms.common.ConnectionResult</td> 872 </tr> 873 874 875</table> 876 877 878 879 880 881 882 883<div class="jd-descr"> 884 885 886<h2>Class Overview</h2> 887<p itemprop="articleBody">Contains all possible error codes for when a client fails to connect to Google Play services. 888 These error codes are used by <code><a href="/reference/com/google/android/gms/common/api/GoogleApiClient.OnConnectionFailedListener.html">GoogleApiClient.OnConnectionFailedListener</a></code>. 889</p> 890 891 892 893 894 895</div><!-- jd-descr --> 896 897 898 899 900 901 902 903 904 905 906 907 908 909 910 911 912<div class="jd-descr"> 913 914 915<h2>Summary</h2> 916 917 918 919 920 921 922 923 924 925 926 927 928 929<!-- =========== ENUM CONSTANT SUMMARY =========== --> 930<table id="constants" class="jd-sumtable"><tr><th colspan="12">Constants</th></tr> 931 932 933 934 <tr class="alt-color api apilevel-" > 935 <td class="jd-typecol">int</td> 936 <td class="jd-linkcol"><a href="/reference/com/google/android/gms/common/ConnectionResult.html#API_UNAVAILABLE">API_UNAVAILABLE</a></td> 937 <td class="jd-descrcol" width="100%"> 938 One of the API components you attempted to connect to is not available. 939 940 941 942 </td> 943 </tr> 944 945 946 <tr class=" api apilevel-" > 947 <td class="jd-typecol">int</td> 948 <td class="jd-linkcol"><a href="/reference/com/google/android/gms/common/ConnectionResult.html#CANCELED">CANCELED</a></td> 949 <td class="jd-descrcol" width="100%"> 950 The client canceled the connection by calling 951 <code><a href="/reference/com/google/android/gms/common/api/GoogleApiClient.html#disconnect()">disconnect()</a></code>. 952 953 954 955 </td> 956 </tr> 957 958 959 <tr class="alt-color api apilevel-" > 960 <td class="jd-typecol">int</td> 961 <td class="jd-linkcol"><a href="/reference/com/google/android/gms/common/ConnectionResult.html#DEVELOPER_ERROR">DEVELOPER_ERROR</a></td> 962 <td class="jd-descrcol" width="100%"> 963 The application is misconfigured. 964 965 966 967 </td> 968 </tr> 969 970 971 <tr class=" api apilevel-" > 972 <td class="jd-typecol">int</td> 973 <td class="jd-linkcol"><a href="/reference/com/google/android/gms/common/ConnectionResult.html#DRIVE_EXTERNAL_STORAGE_REQUIRED">DRIVE_EXTERNAL_STORAGE_REQUIRED</a></td> 974 <td class="jd-descrcol" width="100%"> 975 <em> 976 This constant is deprecated. 977 External storage is no longer required. 978</em> 979 980 981 982 </td> 983 </tr> 984 985 986 <tr class="alt-color api apilevel-" > 987 <td class="jd-typecol">int</td> 988 <td class="jd-linkcol"><a href="/reference/com/google/android/gms/common/ConnectionResult.html#INTERNAL_ERROR">INTERNAL_ERROR</a></td> 989 <td class="jd-descrcol" width="100%"> 990 An internal error occurred. 991 992 993 994 </td> 995 </tr> 996 997 998 <tr class=" api apilevel-" > 999 <td class="jd-typecol">int</td> 1000 <td class="jd-linkcol"><a href="/reference/com/google/android/gms/common/ConnectionResult.html#INTERRUPTED">INTERRUPTED</a></td> 1001 <td class="jd-descrcol" width="100%"> 1002 An interrupt occurred while waiting for the connection complete. 1003 1004 1005 1006 </td> 1007 </tr> 1008 1009 1010 <tr class="alt-color api apilevel-" > 1011 <td class="jd-typecol">int</td> 1012 <td class="jd-linkcol"><a href="/reference/com/google/android/gms/common/ConnectionResult.html#INVALID_ACCOUNT">INVALID_ACCOUNT</a></td> 1013 <td class="jd-descrcol" width="100%"> 1014 The client attempted to connect to the service with an invalid account name 1015 specified. 1016 1017 1018 1019 </td> 1020 </tr> 1021 1022 1023 <tr class=" api apilevel-" > 1024 <td class="jd-typecol">int</td> 1025 <td class="jd-linkcol"><a href="/reference/com/google/android/gms/common/ConnectionResult.html#LICENSE_CHECK_FAILED">LICENSE_CHECK_FAILED</a></td> 1026 <td class="jd-descrcol" width="100%"> 1027 The application is not licensed to the user. 1028 1029 1030 1031 </td> 1032 </tr> 1033 1034 1035 <tr class="alt-color api apilevel-" > 1036 <td class="jd-typecol">int</td> 1037 <td class="jd-linkcol"><a href="/reference/com/google/android/gms/common/ConnectionResult.html#NETWORK_ERROR">NETWORK_ERROR</a></td> 1038 <td class="jd-descrcol" width="100%"> 1039 A network error occurred. 1040 1041 1042 1043 </td> 1044 </tr> 1045 1046 1047 <tr class=" api apilevel-" > 1048 <td class="jd-typecol">int</td> 1049 <td class="jd-linkcol"><a href="/reference/com/google/android/gms/common/ConnectionResult.html#RESOLUTION_REQUIRED">RESOLUTION_REQUIRED</a></td> 1050 <td class="jd-descrcol" width="100%"> 1051 Completing the connection requires some form of resolution. 1052 1053 1054 1055 </td> 1056 </tr> 1057 1058 1059 <tr class="alt-color api apilevel-" > 1060 <td class="jd-typecol">int</td> 1061 <td class="jd-linkcol"><a href="/reference/com/google/android/gms/common/ConnectionResult.html#SERVICE_DISABLED">SERVICE_DISABLED</a></td> 1062 <td class="jd-descrcol" width="100%"> 1063 The installed version of Google Play services has been disabled on this device. 1064 1065 1066 1067 </td> 1068 </tr> 1069 1070 1071 <tr class=" api apilevel-" > 1072 <td class="jd-typecol">int</td> 1073 <td class="jd-linkcol"><a href="/reference/com/google/android/gms/common/ConnectionResult.html#SERVICE_INVALID">SERVICE_INVALID</a></td> 1074 <td class="jd-descrcol" width="100%"> 1075 The version of the Google Play services installed on this device is not authentic. 1076 1077 1078 1079 </td> 1080 </tr> 1081 1082 1083 <tr class="alt-color api apilevel-" > 1084 <td class="jd-typecol">int</td> 1085 <td class="jd-linkcol"><a href="/reference/com/google/android/gms/common/ConnectionResult.html#SERVICE_MISSING">SERVICE_MISSING</a></td> 1086 <td class="jd-descrcol" width="100%"> 1087 Google Play services is missing on this device. 1088 1089 1090 1091 </td> 1092 </tr> 1093 1094 1095 <tr class=" api apilevel-" > 1096 <td class="jd-typecol">int</td> 1097 <td class="jd-linkcol"><a href="/reference/com/google/android/gms/common/ConnectionResult.html#SERVICE_VERSION_UPDATE_REQUIRED">SERVICE_VERSION_UPDATE_REQUIRED</a></td> 1098 <td class="jd-descrcol" width="100%"> 1099 The installed version of Google Play services is out of date. 1100 1101 1102 1103 </td> 1104 </tr> 1105 1106 1107 <tr class="alt-color api apilevel-" > 1108 <td class="jd-typecol">int</td> 1109 <td class="jd-linkcol"><a href="/reference/com/google/android/gms/common/ConnectionResult.html#SIGN_IN_REQUIRED">SIGN_IN_REQUIRED</a></td> 1110 <td class="jd-descrcol" width="100%"> 1111 The client attempted to connect to the service but the user is not 1112 signed in. 1113 1114 1115 1116 </td> 1117 </tr> 1118 1119 1120 <tr class=" api apilevel-" > 1121 <td class="jd-typecol">int</td> 1122 <td class="jd-linkcol"><a href="/reference/com/google/android/gms/common/ConnectionResult.html#SUCCESS">SUCCESS</a></td> 1123 <td class="jd-descrcol" width="100%"> 1124 The connection was successful. 1125 1126 1127 1128 </td> 1129 </tr> 1130 1131 1132 <tr class="alt-color api apilevel-" > 1133 <td class="jd-typecol">int</td> 1134 <td class="jd-linkcol"><a href="/reference/com/google/android/gms/common/ConnectionResult.html#TIMEOUT">TIMEOUT</a></td> 1135 <td class="jd-descrcol" width="100%"> 1136 The timeout was exceeded while waiting for the connection to complete. 1137 1138 1139 1140 </td> 1141 </tr> 1142 1143 1144 1145</table> 1146 1147 1148 1149 1150 1151 1152 1153 1154 1155 1156 1157 1158<!-- ======== CONSTRUCTOR SUMMARY ======== --> 1159<table id="pubctors" class="jd-sumtable"><tr><th colspan="12">Public Constructors</th></tr> 1160 1161 1162 1163 1164 <tr class="alt-color api apilevel-" > 1165 <td class="jd-typecol"><nobr> 1166 1167 1168 1169 1170 1171 </nobr> 1172 </td> 1173 <td class="jd-linkcol" width="100%"><nobr> 1174 <span class="sympad"><a href="/reference/com/google/android/gms/common/ConnectionResult.html#ConnectionResult(int, android.app.PendingIntent)">ConnectionResult</a></span>(int statusCode, PendingIntent pendingIntent)</nobr> 1175 1176 <div class="jd-descrdiv"> 1177 Creates a connection result. 1178 1179 1180 1181 </div> 1182 1183 </td></tr> 1184 1185 1186 1187</table> 1188 1189 1190 1191 1192 1193 1194<!-- ========== METHOD SUMMARY =========== --> 1195<table id="pubmethods" class="jd-sumtable"><tr><th colspan="12">Public Methods</th></tr> 1196 1197 1198 1199 1200 <tr class="alt-color api apilevel-" > 1201 <td class="jd-typecol"><nobr> 1202 1203 1204 1205 1206 1207 int</nobr> 1208 </td> 1209 <td class="jd-linkcol" width="100%"><nobr> 1210 <span class="sympad"><a href="/reference/com/google/android/gms/common/ConnectionResult.html#getErrorCode()">getErrorCode</a></span>()</nobr> 1211 1212 <div class="jd-descrdiv"> 1213 Indicates the type of error that interrupted connection. 1214 1215 1216 1217 </div> 1218 1219 </td></tr> 1220 1221 1222 1223 <tr class=" api apilevel-" > 1224 <td class="jd-typecol"><nobr> 1225 1226 1227 1228 1229 1230 PendingIntent</nobr> 1231 </td> 1232 <td class="jd-linkcol" width="100%"><nobr> 1233 <span class="sympad"><a href="/reference/com/google/android/gms/common/ConnectionResult.html#getResolution()">getResolution</a></span>()</nobr> 1234 1235 <div class="jd-descrdiv"> 1236 A pending intent to resolve the connection failure. 1237 1238 1239 1240 </div> 1241 1242 </td></tr> 1243 1244 1245 1246 <tr class="alt-color api apilevel-" > 1247 <td class="jd-typecol"><nobr> 1248 1249 1250 1251 1252 1253 boolean</nobr> 1254 </td> 1255 <td class="jd-linkcol" width="100%"><nobr> 1256 <span class="sympad"><a href="/reference/com/google/android/gms/common/ConnectionResult.html#hasResolution()">hasResolution</a></span>()</nobr> 1257 1258 <div class="jd-descrdiv"> 1259 Returns true if calling <code><a href="/reference/com/google/android/gms/common/ConnectionResult.html#startResolutionForResult(android.app.Activity, int)">startResolutionForResult(Activity, int)</a></code> 1260 will start any intents requiring user interaction. 1261 1262 1263 1264 </div> 1265 1266 </td></tr> 1267 1268 1269 1270 <tr class=" api apilevel-" > 1271 <td class="jd-typecol"><nobr> 1272 1273 1274 1275 1276 1277 boolean</nobr> 1278 </td> 1279 <td class="jd-linkcol" width="100%"><nobr> 1280 <span class="sympad"><a href="/reference/com/google/android/gms/common/ConnectionResult.html#isSuccess()">isSuccess</a></span>()</nobr> 1281 1282 <div class="jd-descrdiv"> 1283 Returns true if the connection was successful. 1284 1285 1286 1287 </div> 1288 1289 </td></tr> 1290 1291 1292 1293 <tr class="alt-color api apilevel-" > 1294 <td class="jd-typecol"><nobr> 1295 1296 1297 1298 1299 1300 void</nobr> 1301 </td> 1302 <td class="jd-linkcol" width="100%"><nobr> 1303 <span class="sympad"><a href="/reference/com/google/android/gms/common/ConnectionResult.html#startResolutionForResult(android.app.Activity, int)">startResolutionForResult</a></span>(Activity activity, int requestCode)</nobr> 1304 1305 <div class="jd-descrdiv"> 1306 Resolves an error by starting any intents requiring user 1307 interaction. 1308 1309 1310 1311 </div> 1312 1313 </td></tr> 1314 1315 1316 1317 <tr class=" api apilevel-" > 1318 <td class="jd-typecol"><nobr> 1319 1320 1321 1322 1323 1324 String</nobr> 1325 </td> 1326 <td class="jd-linkcol" width="100%"><nobr> 1327 <span class="sympad"><a href="/reference/com/google/android/gms/common/ConnectionResult.html#toString()">toString</a></span>()</nobr> 1328 1329 </td></tr> 1330 1331 1332 1333</table> 1334 1335 1336 1337 1338 1339 1340 1341<!-- ========== METHOD SUMMARY =========== --> 1342<table id="inhmethods" class="jd-sumtable"><tr><th> 1343 <a href="#" class="toggle-all" onclick="return toggleAllInherited(this, null)">[Expand]</a> 1344 <div style="clear:left;">Inherited Methods</div></th></tr> 1345 1346 1347<tr class="api apilevel-" > 1348<td colspan="12"> 1349 <a href="#" onclick="return toggleInherited(this, null)" id="inherited-methods-java.lang.Object" class="jd-expando-trigger closed" 1350 ><img id="inherited-methods-java.lang.Object-trigger" 1351 src="/assets/images/triangle-closed.png" 1352 class="jd-expando-trigger-img" /></a> 1353From class 1354 1355 java.lang.Object 1356 1357<div id="inherited-methods-java.lang.Object"> 1358 <div id="inherited-methods-java.lang.Object-list" 1359 class="jd-inheritedlinks"> 1360 </div> 1361 <div id="inherited-methods-java.lang.Object-summary" style="display: none;"> 1362 <table class="jd-sumtable-expando"> 1363 1364 1365 1366 1367 <tr class="alt-color api apilevel-" > 1368 <td class="jd-typecol"><nobr> 1369 1370 1371 1372 1373 1374 Object</nobr> 1375 </td> 1376 <td class="jd-linkcol" width="100%"><nobr> 1377 <span class="sympad">clone</span>()</nobr> 1378 1379 </td></tr> 1380 1381 1382 1383 <tr class=" api apilevel-" > 1384 <td class="jd-typecol"><nobr> 1385 1386 1387 1388 1389 1390 boolean</nobr> 1391 </td> 1392 <td class="jd-linkcol" width="100%"><nobr> 1393 <span class="sympad">equals</span>(Object arg0)</nobr> 1394 1395 </td></tr> 1396 1397 1398 1399 <tr class="alt-color api apilevel-" > 1400 <td class="jd-typecol"><nobr> 1401 1402 1403 1404 1405 1406 void</nobr> 1407 </td> 1408 <td class="jd-linkcol" width="100%"><nobr> 1409 <span class="sympad">finalize</span>()</nobr> 1410 1411 </td></tr> 1412 1413 1414 1415 <tr class=" api apilevel-" > 1416 <td class="jd-typecol"><nobr> 1417 1418 1419 final 1420 1421 1422 Class<?></nobr> 1423 </td> 1424 <td class="jd-linkcol" width="100%"><nobr> 1425 <span class="sympad">getClass</span>()</nobr> 1426 1427 </td></tr> 1428 1429 1430 1431 <tr class="alt-color api apilevel-" > 1432 <td class="jd-typecol"><nobr> 1433 1434 1435 1436 1437 1438 int</nobr> 1439 </td> 1440 <td class="jd-linkcol" width="100%"><nobr> 1441 <span class="sympad">hashCode</span>()</nobr> 1442 1443 </td></tr> 1444 1445 1446 1447 <tr class=" api apilevel-" > 1448 <td class="jd-typecol"><nobr> 1449 1450 1451 final 1452 1453 1454 void</nobr> 1455 </td> 1456 <td class="jd-linkcol" width="100%"><nobr> 1457 <span class="sympad">notify</span>()</nobr> 1458 1459 </td></tr> 1460 1461 1462 1463 <tr class="alt-color api apilevel-" > 1464 <td class="jd-typecol"><nobr> 1465 1466 1467 final 1468 1469 1470 void</nobr> 1471 </td> 1472 <td class="jd-linkcol" width="100%"><nobr> 1473 <span class="sympad">notifyAll</span>()</nobr> 1474 1475 </td></tr> 1476 1477 1478 1479 <tr class=" api apilevel-" > 1480 <td class="jd-typecol"><nobr> 1481 1482 1483 1484 1485 1486 String</nobr> 1487 </td> 1488 <td class="jd-linkcol" width="100%"><nobr> 1489 <span class="sympad">toString</span>()</nobr> 1490 1491 </td></tr> 1492 1493 1494 1495 <tr class="alt-color api apilevel-" > 1496 <td class="jd-typecol"><nobr> 1497 1498 1499 final 1500 1501 1502 void</nobr> 1503 </td> 1504 <td class="jd-linkcol" width="100%"><nobr> 1505 <span class="sympad">wait</span>()</nobr> 1506 1507 </td></tr> 1508 1509 1510 1511 <tr class=" api apilevel-" > 1512 <td class="jd-typecol"><nobr> 1513 1514 1515 final 1516 1517 1518 void</nobr> 1519 </td> 1520 <td class="jd-linkcol" width="100%"><nobr> 1521 <span class="sympad">wait</span>(long arg0, int arg1)</nobr> 1522 1523 </td></tr> 1524 1525 1526 1527 <tr class="alt-color api apilevel-" > 1528 <td class="jd-typecol"><nobr> 1529 1530 1531 final 1532 1533 1534 void</nobr> 1535 </td> 1536 <td class="jd-linkcol" width="100%"><nobr> 1537 <span class="sympad">wait</span>(long arg0)</nobr> 1538 1539 </td></tr> 1540 1541 1542</table> 1543 </div> 1544</div> 1545</td></tr> 1546 1547 1548</table> 1549 1550 1551</div><!-- jd-descr (summary) --> 1552 1553<!-- Details --> 1554 1555 1556 1557 1558 1559 1560 1561 1562<!-- XML Attributes --> 1563 1564 1565<!-- Enum Values --> 1566 1567 1568<!-- Constants --> 1569 1570 1571<!-- ========= ENUM CONSTANTS DETAIL ======== --> 1572<h2>Constants</h2> 1573 1574 1575 1576 1577<A NAME="API_UNAVAILABLE"></A> 1578 1579<div class="jd-details api apilevel-"> 1580 <h4 class="jd-details-title"> 1581 <span class="normal"> 1582 public 1583 static 1584 final 1585 int 1586 </span> 1587 API_UNAVAILABLE 1588 </h4> 1589 <div class="api-level"> 1590 1591 1592 1593 1594 </div> 1595 <div class="jd-details-descr"> 1596 1597 1598 1599 1600 <div class="jd-tagdata jd-tagdescr"><p>One of the API components you attempted to connect to is not available. The API will not 1601 work on this device, and updating Google Play services will not likely solve the problem. 1602 Using the API on the device should be avoided. 1603</p></div> 1604 1605 1606 <div class="jd-tagdata"> 1607 <span class="jd-tagtitle">Constant Value: </span> 1608 <span> 1609 1610 16 1611 (0x00000010) 1612 1613 </span> 1614 </div> 1615 1616 </div> 1617</div> 1618 1619 1620 1621<A NAME="CANCELED"></A> 1622 1623<div class="jd-details api apilevel-"> 1624 <h4 class="jd-details-title"> 1625 <span class="normal"> 1626 public 1627 static 1628 final 1629 int 1630 </span> 1631 CANCELED 1632 </h4> 1633 <div class="api-level"> 1634 1635 1636 1637 1638 </div> 1639 <div class="jd-details-descr"> 1640 1641 1642 1643 1644 <div class="jd-tagdata jd-tagdescr"><p>The client canceled the connection by calling 1645 <code><a href="/reference/com/google/android/gms/common/api/GoogleApiClient.html#disconnect()">disconnect()</a></code>. Only returned by 1646 <code><a href="/reference/com/google/android/gms/common/api/GoogleApiClient.html#blockingConnect()">blockingConnect()</a></code>. 1647</p></div> 1648 1649 1650 <div class="jd-tagdata"> 1651 <span class="jd-tagtitle">Constant Value: </span> 1652 <span> 1653 1654 13 1655 (0x0000000d) 1656 1657 </span> 1658 </div> 1659 1660 </div> 1661</div> 1662 1663 1664 1665<A NAME="DEVELOPER_ERROR"></A> 1666 1667<div class="jd-details api apilevel-"> 1668 <h4 class="jd-details-title"> 1669 <span class="normal"> 1670 public 1671 static 1672 final 1673 int 1674 </span> 1675 DEVELOPER_ERROR 1676 </h4> 1677 <div class="api-level"> 1678 1679 1680 1681 1682 </div> 1683 <div class="jd-details-descr"> 1684 1685 1686 1687 1688 <div class="jd-tagdata jd-tagdescr"><p>The application is misconfigured. This error is not recoverable and will be treated as fatal. 1689 The developer should look at the logs after this to determine more actionable information. 1690</p></div> 1691 1692 1693 <div class="jd-tagdata"> 1694 <span class="jd-tagtitle">Constant Value: </span> 1695 <span> 1696 1697 10 1698 (0x0000000a) 1699 1700 </span> 1701 </div> 1702 1703 </div> 1704</div> 1705 1706 1707 1708<A NAME="DRIVE_EXTERNAL_STORAGE_REQUIRED"></A> 1709 1710<div class="jd-details api apilevel-"> 1711 <h4 class="jd-details-title"> 1712 <span class="normal"> 1713 public 1714 static 1715 final 1716 int 1717 </span> 1718 DRIVE_EXTERNAL_STORAGE_REQUIRED 1719 </h4> 1720 <div class="api-level"> 1721 1722 1723 1724 1725 </div> 1726 <div class="jd-details-descr"> 1727 1728 1729 1730 <p> 1731 <p class="caution"><strong> 1732 This constant is deprecated.</strong><br/> 1733 External storage is no longer required. 1734 1735 </p> 1736 <div class="jd-tagdata jd-tagdescr"><p>The Drive API requires external storage (such as an SD card), but no external storage is 1737 mounted. This error is recoverable if the user installs external storage (if none is present) 1738 and ensures that it is mounted (which may involve disabling USB storage mode, formatting the 1739 storage, or other initialization as required by the device). 1740 1741 <p>This error should never be returned on a device with emulated external storage. On devices 1742 with emulated external storage, the emulated "external storage" is always present regardless 1743 of whether the device also has removable storage.</p></div> 1744 1745 1746 <div class="jd-tagdata"> 1747 <span class="jd-tagtitle">Constant Value: </span> 1748 <span> 1749 1750 1500 1751 (0x000005dc) 1752 1753 </span> 1754 </div> 1755 1756 </div> 1757</div> 1758 1759 1760 1761<A NAME="INTERNAL_ERROR"></A> 1762 1763<div class="jd-details api apilevel-"> 1764 <h4 class="jd-details-title"> 1765 <span class="normal"> 1766 public 1767 static 1768 final 1769 int 1770 </span> 1771 INTERNAL_ERROR 1772 </h4> 1773 <div class="api-level"> 1774 1775 1776 1777 1778 </div> 1779 <div class="jd-details-descr"> 1780 1781 1782 1783 1784 <div class="jd-tagdata jd-tagdescr"><p>An internal error occurred. Retrying should resolve the problem. 1785</p></div> 1786 1787 1788 <div class="jd-tagdata"> 1789 <span class="jd-tagtitle">Constant Value: </span> 1790 <span> 1791 1792 8 1793 (0x00000008) 1794 1795 </span> 1796 </div> 1797 1798 </div> 1799</div> 1800 1801 1802 1803<A NAME="INTERRUPTED"></A> 1804 1805<div class="jd-details api apilevel-"> 1806 <h4 class="jd-details-title"> 1807 <span class="normal"> 1808 public 1809 static 1810 final 1811 int 1812 </span> 1813 INTERRUPTED 1814 </h4> 1815 <div class="api-level"> 1816 1817 1818 1819 1820 </div> 1821 <div class="jd-details-descr"> 1822 1823 1824 1825 1826 <div class="jd-tagdata jd-tagdescr"><p>An interrupt occurred while waiting for the connection complete. Only returned by 1827 <code><a href="/reference/com/google/android/gms/common/api/GoogleApiClient.html#blockingConnect()">blockingConnect()</a></code>. 1828</p></div> 1829 1830 1831 <div class="jd-tagdata"> 1832 <span class="jd-tagtitle">Constant Value: </span> 1833 <span> 1834 1835 15 1836 (0x0000000f) 1837 1838 </span> 1839 </div> 1840 1841 </div> 1842</div> 1843 1844 1845 1846<A NAME="INVALID_ACCOUNT"></A> 1847 1848<div class="jd-details api apilevel-"> 1849 <h4 class="jd-details-title"> 1850 <span class="normal"> 1851 public 1852 static 1853 final 1854 int 1855 </span> 1856 INVALID_ACCOUNT 1857 </h4> 1858 <div class="api-level"> 1859 1860 1861 1862 1863 </div> 1864 <div class="jd-details-descr"> 1865 1866 1867 1868 1869 <div class="jd-tagdata jd-tagdescr"><p>The client attempted to connect to the service with an invalid account name 1870 specified. 1871</p></div> 1872 1873 1874 <div class="jd-tagdata"> 1875 <span class="jd-tagtitle">Constant Value: </span> 1876 <span> 1877 1878 5 1879 (0x00000005) 1880 1881 </span> 1882 </div> 1883 1884 </div> 1885</div> 1886 1887 1888 1889<A NAME="LICENSE_CHECK_FAILED"></A> 1890 1891<div class="jd-details api apilevel-"> 1892 <h4 class="jd-details-title"> 1893 <span class="normal"> 1894 public 1895 static 1896 final 1897 int 1898 </span> 1899 LICENSE_CHECK_FAILED 1900 </h4> 1901 <div class="api-level"> 1902 1903 1904 1905 1906 </div> 1907 <div class="jd-details-descr"> 1908 1909 1910 1911 1912 <div class="jd-tagdata jd-tagdescr"><p>The application is not licensed to the user. This error is not recoverable and will be 1913 treated as fatal. 1914</p></div> 1915 1916 1917 <div class="jd-tagdata"> 1918 <span class="jd-tagtitle">Constant Value: </span> 1919 <span> 1920 1921 11 1922 (0x0000000b) 1923 1924 </span> 1925 </div> 1926 1927 </div> 1928</div> 1929 1930 1931 1932<A NAME="NETWORK_ERROR"></A> 1933 1934<div class="jd-details api apilevel-"> 1935 <h4 class="jd-details-title"> 1936 <span class="normal"> 1937 public 1938 static 1939 final 1940 int 1941 </span> 1942 NETWORK_ERROR 1943 </h4> 1944 <div class="api-level"> 1945 1946 1947 1948 1949 </div> 1950 <div class="jd-details-descr"> 1951 1952 1953 1954 1955 <div class="jd-tagdata jd-tagdescr"><p>A network error occurred. Retrying should resolve the problem. 1956</p></div> 1957 1958 1959 <div class="jd-tagdata"> 1960 <span class="jd-tagtitle">Constant Value: </span> 1961 <span> 1962 1963 7 1964 (0x00000007) 1965 1966 </span> 1967 </div> 1968 1969 </div> 1970</div> 1971 1972 1973 1974<A NAME="RESOLUTION_REQUIRED"></A> 1975 1976<div class="jd-details api apilevel-"> 1977 <h4 class="jd-details-title"> 1978 <span class="normal"> 1979 public 1980 static 1981 final 1982 int 1983 </span> 1984 RESOLUTION_REQUIRED 1985 </h4> 1986 <div class="api-level"> 1987 1988 1989 1990 1991 </div> 1992 <div class="jd-details-descr"> 1993 1994 1995 1996 1997 <div class="jd-tagdata jd-tagdescr"><p>Completing the connection requires some form of resolution. A resolution will be available 1998 to be started with <code><a href="/reference/com/google/android/gms/common/ConnectionResult.html#startResolutionForResult(android.app.Activity, int)">startResolutionForResult(Activity, int)</a></code>. 1999 If the result returned is <code><a href="/reference/android/app/Activity.html#RESULT_OK">RESULT_OK</a></code>, then further attempts to connect 2000 should either complete or continue on to the next issue that needs to be resolved. 2001</p></div> 2002 2003 2004 <div class="jd-tagdata"> 2005 <span class="jd-tagtitle">Constant Value: </span> 2006 <span> 2007 2008 6 2009 (0x00000006) 2010 2011 </span> 2012 </div> 2013 2014 </div> 2015</div> 2016 2017 2018 2019<A NAME="SERVICE_DISABLED"></A> 2020 2021<div class="jd-details api apilevel-"> 2022 <h4 class="jd-details-title"> 2023 <span class="normal"> 2024 public 2025 static 2026 final 2027 int 2028 </span> 2029 SERVICE_DISABLED 2030 </h4> 2031 <div class="api-level"> 2032 2033 2034 2035 2036 </div> 2037 <div class="jd-details-descr"> 2038 2039 2040 2041 2042 <div class="jd-tagdata jd-tagdescr"><p>The installed version of Google Play services has been disabled on this device. 2043 The calling activity should pass this error code to 2044 <code><a href="/reference/com/google/android/gms/common/GooglePlayServicesUtil.html#getErrorDialog(int, android.app.Activity, int)">getErrorDialog(int, Activity, int)</a></code> to get a localized error dialog 2045 that will resolve the error when shown. 2046</p></div> 2047 2048 2049 <div class="jd-tagdata"> 2050 <span class="jd-tagtitle">Constant Value: </span> 2051 <span> 2052 2053 3 2054 (0x00000003) 2055 2056 </span> 2057 </div> 2058 2059 </div> 2060</div> 2061 2062 2063 2064<A NAME="SERVICE_INVALID"></A> 2065 2066<div class="jd-details api apilevel-"> 2067 <h4 class="jd-details-title"> 2068 <span class="normal"> 2069 public 2070 static 2071 final 2072 int 2073 </span> 2074 SERVICE_INVALID 2075 </h4> 2076 <div class="api-level"> 2077 2078 2079 2080 2081 </div> 2082 <div class="jd-details-descr"> 2083 2084 2085 2086 2087 <div class="jd-tagdata jd-tagdescr"><p>The version of the Google Play services installed on this device is not authentic. 2088</p></div> 2089 2090 2091 <div class="jd-tagdata"> 2092 <span class="jd-tagtitle">Constant Value: </span> 2093 <span> 2094 2095 9 2096 (0x00000009) 2097 2098 </span> 2099 </div> 2100 2101 </div> 2102</div> 2103 2104 2105 2106<A NAME="SERVICE_MISSING"></A> 2107 2108<div class="jd-details api apilevel-"> 2109 <h4 class="jd-details-title"> 2110 <span class="normal"> 2111 public 2112 static 2113 final 2114 int 2115 </span> 2116 SERVICE_MISSING 2117 </h4> 2118 <div class="api-level"> 2119 2120 2121 2122 2123 </div> 2124 <div class="jd-details-descr"> 2125 2126 2127 2128 2129 <div class="jd-tagdata jd-tagdescr"><p>Google Play services is missing on this device. 2130 The calling activity should pass this error code to 2131 <code><a href="/reference/com/google/android/gms/common/GooglePlayServicesUtil.html#getErrorDialog(int, android.app.Activity, int)">getErrorDialog(int, Activity, int)</a></code> to get a localized error dialog 2132 that will resolve the error when shown. 2133</p></div> 2134 2135 2136 <div class="jd-tagdata"> 2137 <span class="jd-tagtitle">Constant Value: </span> 2138 <span> 2139 2140 1 2141 (0x00000001) 2142 2143 </span> 2144 </div> 2145 2146 </div> 2147</div> 2148 2149 2150 2151<A NAME="SERVICE_VERSION_UPDATE_REQUIRED"></A> 2152 2153<div class="jd-details api apilevel-"> 2154 <h4 class="jd-details-title"> 2155 <span class="normal"> 2156 public 2157 static 2158 final 2159 int 2160 </span> 2161 SERVICE_VERSION_UPDATE_REQUIRED 2162 </h4> 2163 <div class="api-level"> 2164 2165 2166 2167 2168 </div> 2169 <div class="jd-details-descr"> 2170 2171 2172 2173 2174 <div class="jd-tagdata jd-tagdescr"><p>The installed version of Google Play services is out of date. 2175 The calling activity should pass this error code to 2176 <code><a href="/reference/com/google/android/gms/common/GooglePlayServicesUtil.html#getErrorDialog(int, android.app.Activity, int)">getErrorDialog(int, Activity, int)</a></code> to get a localized error dialog 2177 that will resolve the error when shown. 2178</p></div> 2179 2180 2181 <div class="jd-tagdata"> 2182 <span class="jd-tagtitle">Constant Value: </span> 2183 <span> 2184 2185 2 2186 (0x00000002) 2187 2188 </span> 2189 </div> 2190 2191 </div> 2192</div> 2193 2194 2195 2196<A NAME="SIGN_IN_REQUIRED"></A> 2197 2198<div class="jd-details api apilevel-"> 2199 <h4 class="jd-details-title"> 2200 <span class="normal"> 2201 public 2202 static 2203 final 2204 int 2205 </span> 2206 SIGN_IN_REQUIRED 2207 </h4> 2208 <div class="api-level"> 2209 2210 2211 2212 2213 </div> 2214 <div class="jd-details-descr"> 2215 2216 2217 2218 2219 <div class="jd-tagdata jd-tagdescr"><p>The client attempted to connect to the service but the user is not 2220 signed in. The client may choose to continue without using the API or it 2221 may call <code><a href="/reference/com/google/android/gms/common/ConnectionResult.html#startResolutionForResult(android.app.Activity, int)">startResolutionForResult(Activity, int)</a></code> to 2222 prompt the user to sign in. After the sign in 2223 activity returns with <code><a href="/reference/android/app/Activity.html#RESULT_OK">RESULT_OK</a></code> further attempts to connect 2224 should succeed. 2225</p></div> 2226 2227 2228 <div class="jd-tagdata"> 2229 <span class="jd-tagtitle">Constant Value: </span> 2230 <span> 2231 2232 4 2233 (0x00000004) 2234 2235 </span> 2236 </div> 2237 2238 </div> 2239</div> 2240 2241 2242 2243<A NAME="SUCCESS"></A> 2244 2245<div class="jd-details api apilevel-"> 2246 <h4 class="jd-details-title"> 2247 <span class="normal"> 2248 public 2249 static 2250 final 2251 int 2252 </span> 2253 SUCCESS 2254 </h4> 2255 <div class="api-level"> 2256 2257 2258 2259 2260 </div> 2261 <div class="jd-details-descr"> 2262 2263 2264 2265 2266 <div class="jd-tagdata jd-tagdescr"><p>The connection was successful. 2267</p></div> 2268 2269 2270 <div class="jd-tagdata"> 2271 <span class="jd-tagtitle">Constant Value: </span> 2272 <span> 2273 2274 0 2275 (0x00000000) 2276 2277 </span> 2278 </div> 2279 2280 </div> 2281</div> 2282 2283 2284 2285<A NAME="TIMEOUT"></A> 2286 2287<div class="jd-details api apilevel-"> 2288 <h4 class="jd-details-title"> 2289 <span class="normal"> 2290 public 2291 static 2292 final 2293 int 2294 </span> 2295 TIMEOUT 2296 </h4> 2297 <div class="api-level"> 2298 2299 2300 2301 2302 </div> 2303 <div class="jd-details-descr"> 2304 2305 2306 2307 2308 <div class="jd-tagdata jd-tagdescr"><p>The timeout was exceeded while waiting for the connection to complete. Only returned by 2309 <code><a href="/reference/com/google/android/gms/common/api/GoogleApiClient.html#blockingConnect()">blockingConnect()</a></code>. 2310</p></div> 2311 2312 2313 <div class="jd-tagdata"> 2314 <span class="jd-tagtitle">Constant Value: </span> 2315 <span> 2316 2317 14 2318 (0x0000000e) 2319 2320 </span> 2321 </div> 2322 2323 </div> 2324</div> 2325 2326 2327 2328 2329<!-- Fields --> 2330 2331 2332<!-- Public ctors --> 2333 2334 2335<!-- ========= CONSTRUCTOR DETAIL ======== --> 2336<h2>Public Constructors</h2> 2337 2338 2339 2340<A NAME="ConnectionResult(int, android.app.PendingIntent)"></A> 2341 2342<div class="jd-details api apilevel-"> 2343 <h4 class="jd-details-title"> 2344 <span class="normal"> 2345 public 2346 2347 2348 2349 2350 2351 </span> 2352 <span class="sympad">ConnectionResult</span> 2353 <span class="normal">(int statusCode, PendingIntent pendingIntent)</span> 2354 </h4> 2355 <div class="api-level"> 2356 <div></div> 2357 2358 2359 2360 </div> 2361 <div class="jd-details-descr"> 2362 2363 2364 2365 2366 <div class="jd-tagdata jd-tagdescr"><p>Creates a connection result.</p></div> 2367 <div class="jd-tagdata"> 2368 <h5 class="jd-tagtitle">Parameters</h5> 2369 <table class="jd-tagtable"> 2370 <tr> 2371 <th>statusCode</td> 2372 <td>The status code.</td> 2373 </tr> 2374 <tr> 2375 <th>pendingIntent</td> 2376 <td>A pending intent that will resolve the issue when started, or null. 2377</td> 2378 </tr> 2379 </table> 2380 </div> 2381 2382 </div> 2383</div> 2384 2385 2386 2387 2388 2389<!-- ========= CONSTRUCTOR DETAIL ======== --> 2390<!-- Protected ctors --> 2391 2392 2393 2394<!-- ========= METHOD DETAIL ======== --> 2395<!-- Public methdos --> 2396 2397<h2>Public Methods</h2> 2398 2399 2400 2401<A NAME="getErrorCode()"></A> 2402 2403<div class="jd-details api apilevel-"> 2404 <h4 class="jd-details-title"> 2405 <span class="normal"> 2406 public 2407 2408 2409 2410 2411 int 2412 </span> 2413 <span class="sympad">getErrorCode</span> 2414 <span class="normal">()</span> 2415 </h4> 2416 <div class="api-level"> 2417 <div></div> 2418 2419 2420 2421 </div> 2422 <div class="jd-details-descr"> 2423 2424 2425 2426 2427 <div class="jd-tagdata jd-tagdescr"><p>Indicates the type of error that interrupted connection.</p></div> 2428 <div class="jd-tagdata"> 2429 <h5 class="jd-tagtitle">Returns</h5> 2430 <ul class="nolist"><li>the error code, or <code><a href="/reference/com/google/android/gms/common/ConnectionResult.html#SUCCESS">SUCCESS</a></code> if no error occurred. 2431</li></ul> 2432 </div> 2433 2434 </div> 2435</div> 2436 2437 2438<A NAME="getResolution()"></A> 2439 2440<div class="jd-details api apilevel-"> 2441 <h4 class="jd-details-title"> 2442 <span class="normal"> 2443 public 2444 2445 2446 2447 2448 PendingIntent 2449 </span> 2450 <span class="sympad">getResolution</span> 2451 <span class="normal">()</span> 2452 </h4> 2453 <div class="api-level"> 2454 <div></div> 2455 2456 2457 2458 </div> 2459 <div class="jd-details-descr"> 2460 2461 2462 2463 2464 <div class="jd-tagdata jd-tagdescr"><p>A pending intent to resolve the connection failure. This intent can be started with 2465 <code><a href="/reference/android/app/Activity.html#startIntentSenderForResult(android.content.IntentSender, int, android.content.Intent, int, int, int)">startIntentSenderForResult(IntentSender, int, Intent, int, int, int)</a></code> 2466 to present UI to solve the issue.</p></div> 2467 <div class="jd-tagdata"> 2468 <h5 class="jd-tagtitle">Returns</h5> 2469 <ul class="nolist"><li>The pending intent to resolve the connection failure. 2470</li></ul> 2471 </div> 2472 2473 </div> 2474</div> 2475 2476 2477<A NAME="hasResolution()"></A> 2478 2479<div class="jd-details api apilevel-"> 2480 <h4 class="jd-details-title"> 2481 <span class="normal"> 2482 public 2483 2484 2485 2486 2487 boolean 2488 </span> 2489 <span class="sympad">hasResolution</span> 2490 <span class="normal">()</span> 2491 </h4> 2492 <div class="api-level"> 2493 <div></div> 2494 2495 2496 2497 </div> 2498 <div class="jd-details-descr"> 2499 2500 2501 2502 2503 <div class="jd-tagdata jd-tagdescr"><p>Returns true if calling <code><a href="/reference/com/google/android/gms/common/ConnectionResult.html#startResolutionForResult(android.app.Activity, int)">startResolutionForResult(Activity, int)</a></code> 2504 will start any intents requiring user interaction.</p></div> 2505 <div class="jd-tagdata"> 2506 <h5 class="jd-tagtitle">Returns</h5> 2507 <ul class="nolist"><li>true if there is a resolution that can be started. 2508</li></ul> 2509 </div> 2510 2511 </div> 2512</div> 2513 2514 2515<A NAME="isSuccess()"></A> 2516 2517<div class="jd-details api apilevel-"> 2518 <h4 class="jd-details-title"> 2519 <span class="normal"> 2520 public 2521 2522 2523 2524 2525 boolean 2526 </span> 2527 <span class="sympad">isSuccess</span> 2528 <span class="normal">()</span> 2529 </h4> 2530 <div class="api-level"> 2531 <div></div> 2532 2533 2534 2535 </div> 2536 <div class="jd-details-descr"> 2537 2538 2539 2540 2541 <div class="jd-tagdata jd-tagdescr"><p>Returns true if the connection was successful.</p></div> 2542 <div class="jd-tagdata"> 2543 <h5 class="jd-tagtitle">Returns</h5> 2544 <ul class="nolist"><li>true if the connection was successful, false if there was an error. 2545</li></ul> 2546 </div> 2547 2548 </div> 2549</div> 2550 2551 2552<A NAME="startResolutionForResult(android.app.Activity, int)"></A> 2553 2554<div class="jd-details api apilevel-"> 2555 <h4 class="jd-details-title"> 2556 <span class="normal"> 2557 public 2558 2559 2560 2561 2562 void 2563 </span> 2564 <span class="sympad">startResolutionForResult</span> 2565 <span class="normal">(Activity activity, int requestCode)</span> 2566 </h4> 2567 <div class="api-level"> 2568 <div></div> 2569 2570 2571 2572 </div> 2573 <div class="jd-details-descr"> 2574 2575 2576 2577 2578 <div class="jd-tagdata jd-tagdescr"><p>Resolves an error by starting any intents requiring user 2579 interaction. See <code><a href="/reference/com/google/android/gms/common/ConnectionResult.html#SIGN_IN_REQUIRED">SIGN_IN_REQUIRED</a></code>, and 2580 <code><a href="/reference/com/google/android/gms/common/ConnectionResult.html#RESOLUTION_REQUIRED">RESOLUTION_REQUIRED</a></code>.</p></div> 2581 <div class="jd-tagdata"> 2582 <h5 class="jd-tagtitle">Parameters</h5> 2583 <table class="jd-tagtable"> 2584 <tr> 2585 <th>activity</td> 2586 <td>An Activity context to use to resolve the issue. The activity's 2587 onActivityResult method will be invoked after the user is done. If the 2588 resultCode is <code><a href="/reference/android/app/Activity.html#RESULT_OK">RESULT_OK</a></code>, the application should try to 2589 connect again.</td> 2590 </tr> 2591 <tr> 2592 <th>requestCode</td> 2593 <td>The request code to pass to onActivityResult.</td> 2594 </tr> 2595 </table> 2596 </div> 2597 <div class="jd-tagdata"> 2598 <h5 class="jd-tagtitle">Throws</h5> 2599 <table class="jd-tagtable"> 2600 <tr> 2601 <th>IntentSender.SendIntentException</td> 2602 <td>If the resolution intent has been canceled or is 2603 no longer able to execute the request. 2604</td> 2605 </tr> 2606 </table> 2607 </div> 2608 2609 </div> 2610</div> 2611 2612 2613<A NAME="toString()"></A> 2614 2615<div class="jd-details api apilevel-"> 2616 <h4 class="jd-details-title"> 2617 <span class="normal"> 2618 public 2619 2620 2621 2622 2623 String 2624 </span> 2625 <span class="sympad">toString</span> 2626 <span class="normal">()</span> 2627 </h4> 2628 <div class="api-level"> 2629 <div></div> 2630 2631 2632 2633 </div> 2634 <div class="jd-details-descr"> 2635 2636 2637 2638 2639 <div class="jd-tagdata jd-tagdescr"><p></p></div> 2640 2641 </div> 2642</div> 2643 2644 2645 2646 2647 2648<!-- ========= METHOD DETAIL ======== --> 2649 2650 2651 2652<!-- ========= END OF CLASS DATA ========= --> 2653<A NAME="navbar_top"></A> 2654 2655<div id="footer" class="wrap" > 2656 2657 2658 <div id="copyright"> 2659 2660 Except as noted, this content is licensed under <a 2661 href="http://www.apache.org/licenses/LICENSE-2.0">Apache 2.0</a>. 2662 For details and restrictions, see the <a href="/license.html"> 2663 Content License</a>. 2664 </div> 2665 <div id="build_info"> 2666 2667<script src="/timestamp.js" type="text/javascript"></script> 2668<script>document.write(BUILD_TIMESTAMP)</script> 2669 2670 </div> 2671 2672 2673 <div id="footerlinks"> 2674 2675 <p> 2676 <a href="/about/index.html">About Android</a> | 2677 <a href="/legal.html">Legal</a> | 2678 <a href="/support.html">Support</a> 2679 </p> 2680 </div> 2681 2682</div> <!-- end footer --> 2683</div> <!-- jd-content --> 2684 2685</div><!-- end doc-content --> 2686 2687</div> <!-- end body-content --> 2688 2689 2690 2691 2692 2693 2694</body> 2695</html> 2696