皮皮学,免费搜题
登录
搜题
【简答题】
从 Android 8.0 开始创建通知时必须提供通知通道,否则通知不会显示,推荐使用 NotificationCompat.Builder 对象构建通知界面,并提供通道通道 ID 。请根据注释在空白划线处填写所需代码。 // 创建显式意图,用于启动 NotificationActivity 类 Intent intent = new Intent(this, NotificationActivity.class); // 将 Intent 转换成启动 Activity 的 PendingIntent PendingIntent pi = (1)________________________ (this, 0, intent, 0); // 从系统服务中取得 NotificationManager 对象 NotificationManager manager = (2)________________________ (NOTIFICATION_SERVICE); // 创建 NotificationCompat.Builder 对象,从 Android 8.0 开始 , 必须提供通知通道 ID Notification notification = (3)_____________________________ (this,CHANNEL_ID) // 设置通知内容标题 . (4)______________ (" 通知 ") // 设置通知内容文本 . (5)______________ (" 关于全国职业院校技能大赛报名工作的通知 ") // 设置通知发布时间为当前时间 . (6)______________ (System.currentTimeMillis()) // 设置通知小图标为 R.mipmap.ic_launcher . (7)______________ (R.mipmap.ic_launcher) // 设置通知大图标为 R.mipmap.ic_launcher ,注意方法参数要求 Bitmap 类型 .(8)____________(BitmapFactory.decodeResource(getResources(), R.mipmap.ic_launcher)) // 设置通知点击后启动 Activity 的延时意图 . (9)____________ // 设置通知声音、闪灯、振动为默认效果 . (10)_____________________________ // 设置长文本样式 .setStyle((11)_____________________________ .bigText(" 为加强管理,提高工作效率, ”+ “ 做好 2019 年全国职业院校技能大赛筹备工作, " + " 决定启动 2019 年大赛网上报名工作。现就有关事项通知如下。 ")) // 设置大图片样式 .setStyle((12)_____________________________ .bigPicture(BitmapFactory.decodeResource(getResources(), R.drawable.big_image))) // 设置通知优先级 . (13)____________ (NotificationCompat.PRIORITY_MAX) // 设置为点击通知后自动在状态栏消失 . (14)____________ (true) // 将 NotificationCompat.Builder 转换成 Notification 对象,完成通知构建 . (15)____________; /* 通知发布前,必须为通知管理器设置通知通道对象 */ // 判断 Android 版本是否大于等于 8.0 if(Build.VERSION.SDK_INT >= Build.VERSION_CODES.O){ // 定义通知通道对象 NotificationChannel notificationChannel = // 创建通道对象, CHANNEL_ID 为通道 ID 常量 new NotificationChannel(CHANNEL_ID, // 通道名称字符串 " 通知通道名称 ", // 通道重要度常量 NotificationManager.IMPORTANCE_DEFAULT); // 设置通道描述字符串 notificationChannel.setDescription(" 通知通道描述 "); // 调用通知管理器 createNotificationChannel 方法创建通知通道 manager.createNotificationChannel(notificationChannel); } // 调用通知管理器 notify() 方法发布通知,第 1 个参数是通知代码 manager. (16)____________ (1, notification);
拍照语音搜题,微信中搜索"皮皮学"使用
参考答案:
参考解析:
知识点:
.
..
皮皮学刷刷变学霸
举一反三
【单选题】Man: Will you make sure all the members of the student advisory committee know what to expect at tomorrow's meeting?Woman: They'll have a briefing this afternoon.Question: What does the woman mean?
A.
The meeting is not expected to last a long time.
B.
He expects to meet the woman at the meeting.
C.
Committee members will be informed before the meeting.
D.
Members will be told to be brief in their comments.
【单选题】The story begins with
A.
a question
B.
anecdote.
C.
a quotation.
D.
a piece of advertisement.
【单选题】The story begins with a funeral for whom?
A.
Miss Emily Grierson
B.
Colonel Sartoris
C.
Colonel Sanders
D.
Emily Dickinson
【判断题】The story begins as Jack enters a home.
A.
正确
B.
错误
【简答题】The story begins with fishing. Once a boy and his father went fishing before bass (a kind of special fish) season opened. They were fishing ea rly in the evening, catching other fish with worms. Then ...
【单选题】What season of the year is it as the story begins?
A.
Christmas
B.
King Arthur’s birthday
C.
Easter
【判断题】医疗器械注册/备案均需进行注册检验。( )(判断)
A.
正确
B.
错误
【单选题】________ is the part of the plot that tells how the story begins.
A.
Rising action
B.
Exposition statement
C.
Conflict
D.
Resolutioin
【单选题】What is the tone as the story begins?
A.
Dry like a newspaper article
B.
An average day with overcast sky
C.
Dreary and ominous
D.
Cheerful, bright and colorful
【多选题】通过形成亲水性通道实现对特异溶质的跨膜转运的蛋白包括( )
A.
孔蛋白
B.
载体蛋白
C.
水孔蛋白
D.
离子通道
相关题目: