1,如何获取notifycation
NotificationManager manager=context.getSystemService(NOTIFICATION_SERVICE);
2.构建notification实例
Notification.Builder().setxxx().setxxx().build();
3.调用manager.notify(id,n);
*如何让notification常驻
n.flags=notification.FLAG_NO_CLEAR;
*用代码清除notification
1,获取Notification.mamager对象
2.manager.cancel(NOTIFICATION_ID);