From c44ba477b3e658db8420a23322181231cbb7cc26 Mon Sep 17 00:00:00 2001 From: Katie McCormick Date: Mon, 20 Aug 2012 12:38:08 -0700 Subject: [PATCH] Doc update: client javadoc fix for @value. Change-Id: I9e1327a21d0755fc10b4e5cb4aa9ecd30053b6ef --- docs/html/guide/google/gcm/adv.jd | 3 +- .../gcm/client-javadoc/allclasses-frame.html | 4 +- .../client-javadoc/allclasses-noframe.html | 4 +- .../android/gcm/GCMBaseIntentService.html | 4 +- .../android/gcm/GCMBroadcastReceiver.html | 4 +- .../com/google/android/gcm/GCMConstants.html | 60 +++-- .../com/google/android/gcm/GCMRegistrar.html | 15 +- .../com/google/android/gcm/package-frame.html | 4 +- .../google/android/gcm/package-summary.html | 4 +- .../com/google/android/gcm/package-tree.html | 4 +- .../gcm/client-javadoc/constant-values.html | 10 +- .../google/gcm/client-javadoc/default.css | 243 ++++++++++++++---- .../gcm/client-javadoc/deprecated-list.html | 4 +- .../google/gcm/client-javadoc/help-doc.html | 4 +- .../google/gcm/client-javadoc/index-all.html | 24 +- .../google/gcm/client-javadoc/index.html | 2 +- .../gcm/client-javadoc/overview-tree.html | 4 +- docs/html/guide/google/gcm/gcm.jd | 20 +- 18 files changed, 307 insertions(+), 110 deletions(-) diff --git a/docs/html/guide/google/gcm/adv.jd b/docs/html/guide/google/gcm/adv.jd index 5cb433f4f58..217412819dd 100644 --- a/docs/html/guide/google/gcm/adv.jd +++ b/docs/html/guide/google/gcm/adv.jd @@ -175,7 +175,8 @@ registerReceiver(mRetryReceiver, filter);
  • The end user uninstalls the application.
  • The 3rd-party server sends a message to GCM server.
  • The GCM server sends the message to the device.
  • -
  • The GCM client receives the message and queries Package Manager, which returns a "package not found" error.
  • +
  • The GCM client receives the message and queries Package Manager about whether there are broadcast receivers configured to receive it, which returns false. +
  • The GCM client informs the GCM server that the application was uninstalled.
  • The GCM server marks the registration ID for deletion.
  • The 3rd-party server sends a message to GCM.
  • diff --git a/docs/html/guide/google/gcm/client-javadoc/allclasses-frame.html b/docs/html/guide/google/gcm/client-javadoc/allclasses-frame.html index 26916d52e32..e1bed36c962 100644 --- a/docs/html/guide/google/gcm/client-javadoc/allclasses-frame.html +++ b/docs/html/guide/google/gcm/client-javadoc/allclasses-frame.html @@ -2,12 +2,12 @@ - + All Classes - + diff --git a/docs/html/guide/google/gcm/client-javadoc/allclasses-noframe.html b/docs/html/guide/google/gcm/client-javadoc/allclasses-noframe.html index 6ae9fe0525e..dc34021fb17 100644 --- a/docs/html/guide/google/gcm/client-javadoc/allclasses-noframe.html +++ b/docs/html/guide/google/gcm/client-javadoc/allclasses-noframe.html @@ -2,12 +2,12 @@ - + All Classes - + diff --git a/docs/html/guide/google/gcm/client-javadoc/com/google/android/gcm/GCMBaseIntentService.html b/docs/html/guide/google/gcm/client-javadoc/com/google/android/gcm/GCMBaseIntentService.html index eed1aea3bf1..ff152185488 100644 --- a/docs/html/guide/google/gcm/client-javadoc/com/google/android/gcm/GCMBaseIntentService.html +++ b/docs/html/guide/google/gcm/client-javadoc/com/google/android/gcm/GCMBaseIntentService.html @@ -2,12 +2,12 @@ - + GCMBaseIntentService - + diff --git a/docs/html/guide/google/gcm/client-javadoc/com/google/android/gcm/GCMBroadcastReceiver.html b/docs/html/guide/google/gcm/client-javadoc/com/google/android/gcm/GCMBroadcastReceiver.html index 2a1c6764a29..ae80bf7f53c 100644 --- a/docs/html/guide/google/gcm/client-javadoc/com/google/android/gcm/GCMBroadcastReceiver.html +++ b/docs/html/guide/google/gcm/client-javadoc/com/google/android/gcm/GCMBroadcastReceiver.html @@ -2,12 +2,12 @@ - + GCMBroadcastReceiver - + diff --git a/docs/html/guide/google/gcm/client-javadoc/com/google/android/gcm/GCMConstants.html b/docs/html/guide/google/gcm/client-javadoc/com/google/android/gcm/GCMConstants.html index f778f066bf8..205bcf0000b 100644 --- a/docs/html/guide/google/gcm/client-javadoc/com/google/android/gcm/GCMConstants.html +++ b/docs/html/guide/google/gcm/client-javadoc/com/google/android/gcm/GCMConstants.html @@ -2,12 +2,12 @@ - + GCMConstants - + @@ -177,8 +177,8 @@

    EXTRA_APPLICATION_PENDING_INTENT
    -          Extra used on INTENT_TO_GCM_REGISTRATION to get the application - id. +          Extra used on "com.google.android.c2dm.intent.REGISTER" to get the + application info. @@ -186,16 +186,25 @@

    EXTRA_ERROR
    -          Extra used on INTENT_FROM_GCM_REGISTRATION_CALLBACK to indicate +          Extra used on "com.google.android.c2dm.intent.REGISTRATION" to indicate an error when the registration fails. static java.lang.String +EXTRA_FROM + +
    +          Extra used on "com.google.android.c2dm.intent.RECEIVE" to indicate which + sender (Google API project id) sent the message. + + + +static java.lang.String EXTRA_REGISTRATION_ID
    -          Extra used on INTENT_FROM_GCM_REGISTRATION_CALLBACK to indicate +          Extra used on "com.google.android.c2dm.intent.REGISTRATION" to indicate the registration id when the registration succeeds. @@ -204,8 +213,8 @@

    EXTRA_SENDER
    -          Extra used on INTENT_TO_GCM_REGISTRATION to indicate the sender - account (a Google email) that owns the application. +          Extra used on "com.google.android.c2dm.intent.REGISTER" to indicate which + senders (Google API project ids) can send messages to the application. @@ -213,7 +222,7 @@

    EXTRA_SPECIAL_MESSAGE
    -          Type of message present in the INTENT_FROM_GCM_MESSAGE intent. +          Type of message present in the "com.google.android.c2dm.intent.RECEIVE" intent. @@ -229,7 +238,7 @@

    EXTRA_UNREGISTERED
    -          Extra used on INTENT_FROM_GCM_REGISTRATION_CALLBACK to indicate +          Extra used on "com.google.android.c2dm.intent.REGISTRATION" to indicate that the application has been unregistered. @@ -388,8 +397,8 @@

     public static final java.lang.String EXTRA_SENDER
    -
    Extra used on INTENT_TO_GCM_REGISTRATION to indicate the sender - account (a Google email) that owns the application. +
    Extra used on "com.google.android.c2dm.intent.REGISTER" to indicate which + senders (Google API project ids) can send messages to the application.

    See Also:
    Constant Field Values
    @@ -401,8 +410,8 @@

     public static final java.lang.String EXTRA_APPLICATION_PENDING_INTENT
    -
    Extra used on INTENT_TO_GCM_REGISTRATION to get the application - id. +
    Extra used on "com.google.android.c2dm.intent.REGISTER" to get the + application info.

    See Also:
    Constant Field Values
    @@ -414,7 +423,7 @@

     public static final java.lang.String EXTRA_UNREGISTERED
    -
    Extra used on INTENT_FROM_GCM_REGISTRATION_CALLBACK to indicate +
    Extra used on "com.google.android.c2dm.intent.REGISTRATION" to indicate that the application has been unregistered.

    @@ -427,7 +436,7 @@

     public static final java.lang.String EXTRA_ERROR
    -
    Extra used on INTENT_FROM_GCM_REGISTRATION_CALLBACK to indicate +
    Extra used on "com.google.android.c2dm.intent.REGISTRATION" to indicate an error when the registration fails. See constants starting with ERROR_ for possible values.

    @@ -441,7 +450,7 @@

     public static final java.lang.String EXTRA_REGISTRATION_ID
    -
    Extra used on INTENT_FROM_GCM_REGISTRATION_CALLBACK to indicate +
    Extra used on "com.google.android.c2dm.intent.REGISTRATION" to indicate the registration id when the registration succeeds.

    @@ -454,7 +463,7 @@

     public static final java.lang.String EXTRA_SPECIAL_MESSAGE
    -
    Type of message present in the INTENT_FROM_GCM_MESSAGE intent. +
    Type of message present in the "com.google.android.c2dm.intent.RECEIVE" intent. This extra is only set for special messages sent from GCM, not for messages originated from the application.

    @@ -482,13 +491,26 @@

    Number of messages deleted by the server because the device was idle. Present only on messages of special type - VALUE_DELETED_MESSAGES + "deleted_messages"

    See Also:
    Constant Field Values

    +

    +EXTRA_FROM

    +
    +public static final java.lang.String EXTRA_FROM
    +
    +
    Extra used on "com.google.android.c2dm.intent.RECEIVE" to indicate which + sender (Google API project id) sent the message. +

    +

    +
    See Also:
    Constant Field Values
    +
    +
    +

    PERMISSION_GCM_INTENTS

    diff --git a/docs/html/guide/google/gcm/client-javadoc/com/google/android/gcm/GCMRegistrar.html b/docs/html/guide/google/gcm/client-javadoc/com/google/android/gcm/GCMRegistrar.html
    index bb486ff5b8f..c29bf90a938 100644
    --- a/docs/html/guide/google/gcm/client-javadoc/com/google/android/gcm/GCMRegistrar.html
    +++ b/docs/html/guide/google/gcm/client-javadoc/com/google/android/gcm/GCMRegistrar.html
    @@ -2,12 +2,12 @@
     
     
     
    -
    +
     
     GCMRegistrar
     
     
    -
    +
     
     
     
    @@ -308,11 +308,12 @@ 

  • It defines at least one BroadcastReceiver with category PACKAGE_NAME.
  • The BroadcastReceiver(s) uses the - permission. -
  • The BroadcastReceiver(s) handles the 3 GCM intents - (, - , - and ). + "com.google.android.c2dm.permission.SEND" + permission. +
  • The BroadcastReceiver(s) handles the 2 GCM intents + ("com.google.android.c2dm.intent.RECEIVE" + and + "com.google.android.c2dm.intent.REGISTRATION"). ...where PACKAGE_NAME is the application package.

    diff --git a/docs/html/guide/google/gcm/client-javadoc/com/google/android/gcm/package-frame.html b/docs/html/guide/google/gcm/client-javadoc/com/google/android/gcm/package-frame.html index 4828eeadcd2..a2a599db7c5 100644 --- a/docs/html/guide/google/gcm/client-javadoc/com/google/android/gcm/package-frame.html +++ b/docs/html/guide/google/gcm/client-javadoc/com/google/android/gcm/package-frame.html @@ -2,12 +2,12 @@ - + com.google.android.gcm - + diff --git a/docs/html/guide/google/gcm/client-javadoc/com/google/android/gcm/package-summary.html b/docs/html/guide/google/gcm/client-javadoc/com/google/android/gcm/package-summary.html index 877248b8fd7..c8e0341f470 100644 --- a/docs/html/guide/google/gcm/client-javadoc/com/google/android/gcm/package-summary.html +++ b/docs/html/guide/google/gcm/client-javadoc/com/google/android/gcm/package-summary.html @@ -2,12 +2,12 @@ - + com.google.android.gcm - + diff --git a/docs/html/guide/google/gcm/client-javadoc/com/google/android/gcm/package-tree.html b/docs/html/guide/google/gcm/client-javadoc/com/google/android/gcm/package-tree.html index bf6fce3413b..0e27efee301 100644 --- a/docs/html/guide/google/gcm/client-javadoc/com/google/android/gcm/package-tree.html +++ b/docs/html/guide/google/gcm/client-javadoc/com/google/android/gcm/package-tree.html @@ -2,12 +2,12 @@ - + com.google.android.gcm Class Hierarchy - + diff --git a/docs/html/guide/google/gcm/client-javadoc/constant-values.html b/docs/html/guide/google/gcm/client-javadoc/constant-values.html index 6ccd123ae22..796d1966c53 100644 --- a/docs/html/guide/google/gcm/client-javadoc/constant-values.html +++ b/docs/html/guide/google/gcm/client-javadoc/constant-values.html @@ -2,12 +2,12 @@ - + Constant Field Values - + @@ -173,6 +173,12 @@

    "error" + +public static final java.lang.String +EXTRA_FROM +"from" + + public static final java.lang.String EXTRA_REGISTRATION_ID diff --git a/docs/html/guide/google/gcm/client-javadoc/default.css b/docs/html/guide/google/gcm/client-javadoc/default.css index 2513e6989e9..f11daf7a917 100644 --- a/docs/html/guide/google/gcm/client-javadoc/default.css +++ b/docs/html/guide/google/gcm/client-javadoc/default.css @@ -530,12 +530,12 @@ h3:target { } .design ol { counter-reset: item; } - .design ol li { + .design ol>li { font-size: 14px; line-height: 20px; list-style-type: none; position: relative; } - .design ol li:before { + .design ol>li:before { content: counter(item) ". "; counter-increment: item; position: absolute; @@ -561,16 +561,18 @@ h3:target { content: "9. "; } .design ol li.value-10:before { content: "10. "; } -.design .with-callouts ol li { +.design .with-callouts ol>li { list-style-position: inside; margin-left: 0; } - .design .with-callouts ol li:before { + .design .with-callouts ol>li:before { display: inline; left: -20px; float: left; width: 17px; color: #33b5e5; font-weight: 500; } +.design .with-callouts ul>li { + list-style-position: outside; } /* special list items */ li.no-bullet { @@ -1079,22 +1081,71 @@ color-stop(50%, #acbc00), color-stop(50%, #bdde00), color-stop(100%, #bdde00)); Print Only ========================================================================== */ @media print { -a { - color: inherit; -} -.nav-x, .nav-y { - display: none; -} -.str { color: #060; } -.kwd { color: #006; font-weight: bold; } -.com { color: #600; font-style: italic; } -.typ { color: #404; font-weight: bold; } -.lit { color: #044; } -.pun { color: #440; } -.pln { color: #000; } -.tag { color: #006; font-weight: bold; } -.atn { color: #404; } -.atv { color: #060; } + /* configure printed page */ + @page { + margin: 0.75in 1in; + widows: 4; + orphans: 4; + } + + /* reset spacing metrics */ + html, body, .wrap { + margin: 0 !important; + padding: 0 !important; + width: auto !important; + } + + /* leave enough space on the left for bullets */ + body { + padding-left: 20px !important; + } + #doc-col { + margin-left: 0; + } + + /* hide a bunch of non-content elements */ + #header, #footer, #nav-x, #side-nav, + .training-nav-top, .training-nav-bottom, + #doc-col .content-footer, + .nav-x, .nav-y, + .paging-links, + a.totop { + display: none !important; + } + + /* remove extra space above page titles */ + #doc-col .content-header { + margin-top: 0; + } + + /* bump up spacing above subheadings */ + h2 { + margin-top: 40px !important; + } + + /* print link URLs where possible and give links default text color */ + p a:after { + content: " (" attr(href) ")"; + font-size: 80%; + } + p a { + word-wrap: break-word; + } + a { + color: inherit; + } + + /* syntax highlighting rules */ + .str { color: #060; } + .kwd { color: #006; font-weight: bold; } + .com { color: #600; font-style: italic; } + .typ { color: #404; font-weight: bold; } + .lit { color: #044; } + .pun { color: #440; } + .pln { color: #000; } + .tag { color: #006; font-weight: bold; } + .atn { color: #404; } + .atv { color: #060; } } /* ============================================================================= @@ -2033,8 +2084,11 @@ div.toggle-content.closed .toggle-content-toggleme { #jd-content img.toggle-content-img { margin:0 5px 5px 0; } -div.toggle-content > p { - padding:0 0 5px; +div.toggle-content p { + margin:10px 0 0; +} +div.toggle-content-toggleme { + padding:0 0 0 15px; } @@ -2145,14 +2199,9 @@ table.blank th, table.blank td { .nolist { list-style:none; - padding:0; - margin:0 0 1em 1em; + margin-left:0; } -.nolist li { - padding:0 0 2px; - margin:0; -} pre.classic { background-color:transparent; @@ -2180,6 +2229,12 @@ p.table-caption { color:#666; } +div.note, +div.caution, +div.warning { + margin: 0 0 15px; +} + p.note, div.note, p.caution, div.caution, p.warning, div.warning { @@ -2898,10 +2953,6 @@ ul#search_filtered { /* SEARCH RESULTS */ -/* disable twiddle and size selectors for left column */ -#leftSearchControl div { - padding:0; -} #leftSearchControl .gsc-twiddle { background-image : none; @@ -3475,7 +3526,7 @@ EndColorStr='#ececec'); .morehover:hover { opacity:1; - height:345px; + height:385px; width:268px; -webkit-transition-property:height, -webkit-opacity; } @@ -3489,7 +3540,7 @@ EndColorStr='#ececec'); .morehover .mid { width:228px; background:url(../images/more_mid.png) repeat-y; - padding:10px 20px 10px 20px; + padding:10px 20px 0 20px; } .morehover .mid .header { @@ -3598,15 +3649,19 @@ a.download-sdk { padding-top: 14px; } +#nav-x .wrap { + min-height:34px; +} + #nav-x .wrap, #searchResults.wrap { max-width:940px; border-bottom:1px solid #CCC; - min-height:34px; - } - +#searchResults.wrap #leftSearchControl { + min-height:700px +} .nav-x { margin-left:0; margin-bottom:0; @@ -3762,7 +3817,8 @@ a.download-sdk { height: 300px; } .slideshow-develop img.play { - width:350px; + max-width:350px; + max-height:240px; margin:20px 0 0 90px; -webkit-transform: perspective(800px ) rotateY( 35deg ); box-shadow: -16px 20px 40px rgba(0, 0, 0, 0.3); @@ -3817,6 +3873,7 @@ a.download-sdk { .feed .feed-nav li { list-style: none; float: left; + height: 21px; /* +4px bottom border = 25px; same as .feed-nav */ margin-right: 25px; cursor: pointer; } @@ -3969,21 +4026,24 @@ a.download-sdk { .landing-docs { margin:20px 0 0; } -.landing-banner { - height:280px; -} .landing-banner .col-6:first-child, -.landing-docs .col-6:first-child { +.landing-docs .col-6:first-child, +.landing-docs .col-12 { margin-left:0; + min-height:280px; } .landing-banner .col-6:last-child, -.landing-docs .col-6:last-child { +.landing-docs .col-6:last-child, +.landing-docs .col-12 { margin-right:0; } .landing-banner h1 { margin-top:0; } +.landing-docs { + clear:left; +} .landing-docs h3 { font-size:14px; line-height:21px; @@ -4002,4 +4062,99 @@ a.download-sdk { .plusone { float:right; -} \ No newline at end of file +} + + + +/************* HOME/LANDING PAGE *****************/ + +.slideshow-home { + height: 500px; + width: 940px; + border-bottom: 1px solid #CCC; + position: relative; + margin: 0; +} +.slideshow-home .frame { + width: 940px; + height: 500px; +} +.slideshow-home .content-left { + float: left; + text-align: center; + vertical-align: center; + margin: 0 0 0 35px; +} +.slideshow-home .content-right { + margin: 80px 0 0 0; +} +.slideshow-home .content-right p { + margin-bottom: 10px; +} +.slideshow-home .content-right p:last-child { + margin-top: 15px; +} +.slideshow-home .content-right h1 { + padding:0; +} +.slideshow-home .item { + height: 500px; + width: 940px; +} +.home-sections { + padding: 30px 20px 20px; + margin: 20px 0; + background: -webkit-linear-gradient(top, #F6F6F6,#F9F9F9); +} +.home-sections ul { + margin: 0; +} +.home-sections ul li { + float: left; + display: block; + list-style: none; + width: 170px; + height: 35px; + border: 1px solid #ccc; + background: white; + margin-right: 10px; + border-radius: 1px; + -webkit-border-radius: 1px; + -moz-border-radius: 1px; + box-shadow: 1px 1px 5px #EEE; + -webkit-box-shadow: 1px 1px 5px #EEE; + -moz-box-shadow: 1px 1px 5px #EEE; + background: white; +} +.home-sections ul li:hover { + background: #F9F9F9; + border: 1px solid #CCC; +} +.home-sections ul li a, +.home-sections ul li a:hover { + font-weight: bold; + margin-top: 8px; + line-height: 18px; + float: left; + width: 100%; + text-align: center; + color: #09c !important; +} +.home-sections ul li a { + font-weight: bold; + margin-top: 8px; + line-height: 18px; + float: left; + width:100%; + text-align:center; +} +.home-sections ul li img { + float: left; + margin: -8px 0 0 10px; +} +.home-sections ul li.last { + margin-right: 0px; +} +#footer { + margin-top: -40px; +} diff --git a/docs/html/guide/google/gcm/client-javadoc/deprecated-list.html b/docs/html/guide/google/gcm/client-javadoc/deprecated-list.html index 6b86bfee271..d9a63c57a79 100644 --- a/docs/html/guide/google/gcm/client-javadoc/deprecated-list.html +++ b/docs/html/guide/google/gcm/client-javadoc/deprecated-list.html @@ -2,12 +2,12 @@ - + Deprecated List - + diff --git a/docs/html/guide/google/gcm/client-javadoc/help-doc.html b/docs/html/guide/google/gcm/client-javadoc/help-doc.html index ffd1f773cae..af1bca85f58 100644 --- a/docs/html/guide/google/gcm/client-javadoc/help-doc.html +++ b/docs/html/guide/google/gcm/client-javadoc/help-doc.html @@ -2,12 +2,12 @@ - + API Help - + diff --git a/docs/html/guide/google/gcm/client-javadoc/index-all.html b/docs/html/guide/google/gcm/client-javadoc/index-all.html index 74e6095da5a..408edee94c8 100644 --- a/docs/html/guide/google/gcm/client-javadoc/index-all.html +++ b/docs/html/guide/google/gcm/client-javadoc/index-all.html @@ -2,12 +2,12 @@ - + Index - + @@ -124,29 +124,33 @@ server that can be retried later.
    EXTRA_APPLICATION_PENDING_INTENT - Static variable in class com.google.android.gcm.GCMConstants -
    Extra used on GCMConstants.INTENT_TO_GCM_REGISTRATION to get the application - id. +
    Extra used on "com.google.android.c2dm.intent.REGISTER" to get the + application info.
    EXTRA_ERROR - Static variable in class com.google.android.gcm.GCMConstants -
    Extra used on GCMConstants.INTENT_FROM_GCM_REGISTRATION_CALLBACK to indicate +
    Extra used on "com.google.android.c2dm.intent.REGISTRATION" to indicate an error when the registration fails. +
    EXTRA_FROM - +Static variable in class com.google.android.gcm.GCMConstants +
    Extra used on "com.google.android.c2dm.intent.RECEIVE" to indicate which + sender (Google API project id) sent the message.
    EXTRA_REGISTRATION_ID - Static variable in class com.google.android.gcm.GCMConstants -
    Extra used on GCMConstants.INTENT_FROM_GCM_REGISTRATION_CALLBACK to indicate +
    Extra used on "com.google.android.c2dm.intent.REGISTRATION" to indicate the registration id when the registration succeeds.
    EXTRA_SENDER - Static variable in class com.google.android.gcm.GCMConstants -
    Extra used on GCMConstants.INTENT_TO_GCM_REGISTRATION to indicate the sender - account (a Google email) that owns the application. +
    Extra used on "com.google.android.c2dm.intent.REGISTER" to indicate which + senders (Google API project ids) can send messages to the application.
    EXTRA_SPECIAL_MESSAGE - Static variable in class com.google.android.gcm.GCMConstants -
    Type of message present in the GCMConstants.INTENT_FROM_GCM_MESSAGE intent. +
    Type of message present in the "com.google.android.c2dm.intent.RECEIVE" intent.
    EXTRA_TOTAL_DELETED - Static variable in class com.google.android.gcm.GCMConstants
    Number of messages deleted by the server because the device was idle.
    EXTRA_UNREGISTERED - Static variable in class com.google.android.gcm.GCMConstants -
    Extra used on GCMConstants.INTENT_FROM_GCM_REGISTRATION_CALLBACK to indicate +
    Extra used on "com.google.android.c2dm.intent.REGISTRATION" to indicate that the application has been unregistered.


  • diff --git a/docs/html/guide/google/gcm/client-javadoc/index.html b/docs/html/guide/google/gcm/client-javadoc/index.html index 26e57f66a81..fa7af905512 100644 --- a/docs/html/guide/google/gcm/client-javadoc/index.html +++ b/docs/html/guide/google/gcm/client-javadoc/index.html @@ -2,7 +2,7 @@ - + Generated Documentation (Untitled) diff --git a/docs/html/guide/google/gcm/client-javadoc/overview-tree.html b/docs/html/guide/google/gcm/client-javadoc/overview-tree.html index c9076f1b1b2..392f3e0fa4b 100644 --- a/docs/html/guide/google/gcm/client-javadoc/overview-tree.html +++ b/docs/html/guide/google/gcm/client-javadoc/overview-tree.html @@ -2,12 +2,12 @@ - + Class Hierarchy - + diff --git a/docs/html/guide/google/gcm/gcm.jd b/docs/html/guide/google/gcm/gcm.jd index f471560bae1..5515f31f433 100644 --- a/docs/html/guide/google/gcm/gcm.jd +++ b/docs/html/guide/google/gcm/gcm.jd @@ -203,7 +203,7 @@ ID in a database.

    The registration ID lasts until the Android application explicitly unregisters itself, or until Google refreshes the registration ID for your Android application.

    -

    Note: When users uninstall an application, it is not automatically unregistered on GCM. It is only unregistered when the GCM server tries to send a message to the device and the device answers that the application is uninstalled. At that point, you server should mark the device as unregistered (the server will receive a NotRegistered error). +

    Note: When users uninstall an application, it is not automatically unregistered on GCM. It is only unregistered when the GCM server tries to send a message to the device and the device answers that the application is uninstalled or it does not have a broadcast receiver configured to receive com.google.android.c2dm.intent.RECEIVE intents. At that point, you server should mark the device as unregistered (the server will receive a NotRegistered error).

    Note that it might take a few minutes for the registration ID to be completed removed from the GCM server. So if the 3rd party server sends a message during this time, it will get a valid message ID, even though the message will not be delivered to the device.

    @@ -546,7 +546,7 @@ private void handleRegistration(Intent intent) { deliver the messages sent by the 3rd-party server to the application running in the device. If the server included key-pair values in the data parameter, they are available as extras in this intent, with the keys being the extra names. GCM also includes an extra called -from which contains the sender ID as an string. +from which contains the sender ID as an string, and another called collapse_key containing the collapse key (when in use).

    Here is an example, again using the MyIntentReceiver class:

    @@ -653,7 +653,7 @@ message sent by the application server. See Advan data A JSON object whose fields represents the key-value pairs of the message's payload data. If present, the payload data it will be included in the Intent as application data, with the key being the extra's name. For instance, "data":{"score":"3x1"} would result in an intent extra named score whose value is the string 3x1. -There is no limit on the number of key/value pairs, though there is a limit on the total size of the message (4kb). Note that the values must be enclosed by strings. If you want to include objects or other non-string data types (such as integers or booleans), you have to do the conversion to string yourself. Also note that the key cannot be a reserved word (from or any word starting with google.). Optional. +There is no limit on the number of key/value pairs, though there is a limit on the total size of the message (4kb). The values could be any JSON object, but we recommend using strings, since the values will be converted to strings in the GCM server anyway. If you want to include objects or other non-string data types (such as integers or booleans), you have to do the conversion to string yourself. Also note that the key cannot be a reserved word (from or any word starting with google.). To complicate things slightly, there are some reserved words (such as collapse_key) that are technically allowed in payload data. However, if the request also contains the word, the value in the request will overwrite the value in the payload data. Hence using words that are defined as field names in this table is not recommended, even in cases where they are technically allowed. Optional. @@ -685,7 +685,8 @@ sent. Optional. The default value is false, and must be a JSON bool data.<key> - Payload data, expressed as parameters prefixed with data. and suffixed as the key. For instance, a parameter of data.score=3x1 would result in an intent extra named score whose value is the string 3x1. There is no limit on the number of key/value parameters, though there is a limit on the total size of the message. Note that the key cannot be a reserved word (from or any word starting with google.). Optional. + Payload data, expressed as parameters prefixed with data. and suffixed as the key. For instance, a parameter of data.score=3x1 would result in an intent extra named score whose value is the string 3x1. There is no limit on the number of key/value parameters, though there is a limit on the total size of the message. Also note that the key cannot be a reserved word (from or any word starting with +google.). To complicate things slightly, there are some reserved words (such as collapse_key) that are technically allowed in payload data. However, if the request also contains the word, the value in the request will overwrite the value in the payload data. Hence using words that are defined as field names in this table is not recommended, even in cases where they are technically allowed. Optional. delay_while_idle @@ -816,7 +817,7 @@ the HTTP response contains a non-200 status code (such as 400, 401, or 503).

  • Otherwise, get the value of error:
  • @@ -850,6 +851,7 @@ has the format of registration_id=canonical ID. The second
    Invalid Registration ID
    Check the formatting of the registration ID that you pass to the server. Make sure it matches the registration ID the phone receives in the com.google.android.c2dm.intent.REGISTRATION intent and that you're not truncating it or adding additional characters.
    Happens when error code is InvalidRegistration.
    +
    Mismatched Sender
    A registration ID is tied to a certain group of senders. When an application registers for GCM usage, it must specify which senders are allowed to send messages. Make sure you're using one of those when trying to send messages to the device. If you switch to a different sender, the existing registration IDs won't work. Happens when error code is MismatchSenderId.
    @@ -860,15 +862,21 @@ Happens when error code is MismatchSenderId.

  • If the application manually unregisters by issuing a com.google.android.c2dm.intent.UNREGISTER intent.
  • If the application is automatically unregistered, which can happen (but is not guaranteed) if the user uninstalls the application.
  • If the registration ID expires. Google might decide to refresh registration IDs.
  • +
  • If the application is updated but the new version does not have a broadcast receiver configured to receive com.google.android.c2dm.intent.RECEIVE intents.
  • For all these cases, you should remove this registration ID from the 3rd-party server and stop using it to send messages.
    Happens when error code is NotRegistered.

    -
    Message Too Big
    +
    Message Too Big
    The total size of the payload data that is included in a message can't exceed 4096 bytes. Note that this includes both the size of the keys as well as the values.
    Happens when error code is MessageTooBig.
    +
    Invalid Data Key
    +
    The payload data contains a key (such as from or any value prefixed by google.) that is used internally by GCM in the com.google.android.c2dm.intent.RECEIVE Intent and cannot be used. Note that some words (such as collapse_key) are also used by GCM but are allowed in the payload, in which case the payload value will be overridden by the GCM value. +
    +Happens when the error code is InvalidDataKey.
    +
    Invalid Time To Live
    The value for the Time to Live field must be an integer representing a duration in seconds between 0 and 2,419,200 (4 weeks). Happens when error code is InvalidTtl.