summaryrefslogtreecommitdiffstats
path: root/core/java/android/service
diff options
context:
space:
mode:
authorScott Main <smain@google.com>2013-04-25 16:57:16 -0700
committerScott Main <smain@google.com>2013-04-25 17:01:53 -0700
commit04667dae3a5e45257c12d11dbcb4fc353a18d842 (patch)
tree1029ee4315f75859584b758d4d37f3b479c7c3b3 /core/java/android/service
parente00a3b80635c830dc57510556231cc40db6651f5 (diff)
downloadframeworks_base-04667dae3a5e45257c12d11dbcb4fc353a18d842.zip
frameworks_base-04667dae3a5e45257c12d11dbcb4fc353a18d842.tar.gz
frameworks_base-04667dae3a5e45257c12d11dbcb4fc353a18d842.tar.bz2
fix javadoc build
also add some docs to the service Change-Id: I712710de403bc000c0a69a2de726bace6e7873bd
Diffstat (limited to 'core/java/android/service')
-rw-r--r--core/java/android/service/notification/NotificationListenerService.java16
1 files changed, 15 insertions, 1 deletions
diff --git a/core/java/android/service/notification/NotificationListenerService.java b/core/java/android/service/notification/NotificationListenerService.java
index 5031d3c..bfea9ca 100644
--- a/core/java/android/service/notification/NotificationListenerService.java
+++ b/core/java/android/service/notification/NotificationListenerService.java
@@ -25,6 +25,20 @@ import android.os.IBinder;
import android.os.ServiceManager;
import android.util.Log;
+/**
+ * A service that receives calls from the system when new notifications are posted or removed.
+ * <p>To extend this class, you must declare the service in your manifest file with
+ * the {@link android.Manifest.permission#BIND_NOTIFICATION_LISTENER_SERVICE} permission
+ * and include an intent filter with the {@link #SERVICE_INTERFACE} action. For example:</p>
+ * <pre>
+ * &lt;service android:name=".NotificationListener"
+ * android:label="&#64;string/service_name"
+ * android:permission="android.permission.BIND_NOTIFICATION_LISTENER_SERVICE">
+ * &lt;intent-filter>
+ * &lt;action android:name="android.service.notification.NotificationListenerService" />
+ * &lt;/intent-filter>
+ * &lt;/service></pre>
+ */
public abstract class NotificationListenerService extends Service {
// TAG = "NotificationListenerService[MySubclass]"
private final String TAG = NotificationListenerService.class.getSimpleName()
@@ -57,7 +71,7 @@ public abstract class NotificationListenerService extends Service {
* notification listener) or because the app has withdrawn the notification.
* <P>
* NOTE: The {@link StatusBarNotification} object you receive will be "light"; that is, the
- * {@link StatusBarNotification#notification} member may be missing some heavyweight
+ * result from {@link StatusBarNotification#getNotification} may be missing some heavyweight
* fields such as {@link android.app.Notification#contentView} and
* {@link android.app.Notification#largeIcon}. However, all other fields on
* {@link StatusBarNotification}, sufficient to match this call with a prior call to