From 3a4d41a654bf00972da9013854ba0e15b2c01fe9 Mon Sep 17 00:00:00 2001 From: John Spurlock Date: Mon, 1 Oct 2012 09:30:49 -0400 Subject: [PATCH] Update javadocs for DreamService. Reflect the new intent-filter protocol, and add a bit about . Also escape xml so it's visible in generated html. Bug:7256474 Change-Id: Id270eeb70601b492458834f19216801b428af4cb --- .../android/service/dreams/DreamService.java | 26 ++++++++++++------- 1 file changed, 16 insertions(+), 10 deletions(-) diff --git a/core/java/android/service/dreams/DreamService.java b/core/java/android/service/dreams/DreamService.java index f97354fb81b02..03b685b595e27 100644 --- a/core/java/android/service/dreams/DreamService.java +++ b/core/java/android/service/dreams/DreamService.java @@ -47,24 +47,30 @@ import com.android.internal.policy.PolicyManager; * *

Dreams should be declared in the manifest as follows:

*
- * {@code
- * 
  *
- *     
- *         
- *         
- *     
+ *     <intent-filter>
+ *         <action android:name="android.service.dreams.DreamService" />
+ *         <category android:name="android.intent.category.DEFAULT" />
+ *     </intent-filter>
  *
- *     
- *     
+ *     <meta-data
  *         android:name="android.service.dream"
  *         android:resource="@xml/my_dream" />
- * 
- * }
+ * </service>
+ * 
+ *

If specified, additional information for the dream is defined using the + * <{@link android.R.styleable#Dream dream}> element. For example:

+ *
+ * (in res/xml/my_dream.xml)
+ *
+ * <dream xmlns:android="http://schemas.android.com/apk/res/android"
+ *     android:settingsActivity="com.example.app/.MyDreamSettingsActivity" />
  * 
*/ public class DreamService extends Service implements Window.Callback {