When a device has a secure lockscreen (PIN, pattern, or password), however, it pides the interface into two spheres: "public", the things that are displayed atop a secure lockscreen and can therefore be seen by anyone; and "private", the world behind that lockscreen, which can only be accessed by supplying the correct authentication.
The user decides what shows on the secure lockscreen
Notifications on the lockscreen followed by the Pattern Unlock when the user attempts to unlock the phone.
When setting up a secure lockscreen, the user can choose to conceal sensitive details from atop the secure lockscreen. In this case the SystemUI considers the notification's visibility level to figure out what can safely be shown.
To control the visibility level, call
Notification.Builder.setVisibility() and specify one of these values:
Notification.VISIBILITY_PUBLIC. Shows the notification's full content. This is the system default if visibility is left unspecified.
Notification.VISIBILITY_PRIVATE. The lockscreen will reveal basic information about the existence of this notification, including its icon and the name of the app that posted it. The rest of the notification's details, however, are not displayed.
If you want to provide a different public version of your notification for the system to display on a secure lockscreen, supply a replacement Notification object in the Notification.publicVersion field.
This is an app's opportunity to create a redacted version of the content that is still useful but does not reveal personal information.
Example: An SMS app whose notifications include the text of the SMS and the sender's name and contact icon. This notification should be VISIBILITY_PRIVATE, but the publicVersion could still contain useful information like "3 new messages" without any other identifying details.
Notification.VISIBILITY_SECRET. Shows only the most minimal information, excluding even the notification's icon.
B.原文的翻译通知的设计 论文网
通知系统允许用户保持呗通知的状态,在你的App中有最近相关的时间消息,例如从一个朋友或者一个日历事件的提醒的一个新的聊天信息。将通知当作一个新闻频道,它能在重要事件发生的时候或者一个用户不注意的用户事件发生时提醒用户,适当同步于所有的Android设备。 Android系统英文文献和中文翻译(6):http://www.751com.cn/fanyi/lunwen_28864.html