- 博客(5)
- 收藏
- 关注
转载 Socket错误记录
找了很久终于找到 bufferReader.close()与out.close()关闭会直接导致sockect.close()故只进行输入火鼠初中一个之后就出现java.net.SocketException: Socket is closed:错误,可能是因为用到了socket.getOutputStream(),socket.getInputStream()的缘故。这里将out.close(...
2019-08-05 16:35:09
80
原创 Service
启动状态开启服务与停止:开启后,若不设置停止,将一直运行 final Intent intent=new Intent(ServiceActivity.this,BindedService.class); findViewById(R.id.start_button).setOnClickListener(new View.OnClickListener() ...
2019-07-16 23:07:46
72
原创 BroadcastReceiver
A类(abstract 类)AS中创建:New>Other>BroadcastReceiverManifest中自动配置:<receiver android:name=".MyReceiver" android:enabled="true" android:exported="true"></receiver>两种类型:Normal ...
2019-07-16 09:20:30
102
转载 系统广播
//关闭或打开飞行模式时的广播Intent.ACTION_AIRPLANE_M;//充电状态,或者电池的电量发生变化;//电池的充电状态、电荷级别改变,不能通过组建声;Intent.ACTION_BATTERY_CH;//表示电池电量低Intent.ACTION_BATTERY_LO;//表示电池电量充足Intent.ACTION_BATTERY_OK;//关闭或打开飞行模...
2019-07-16 09:16:20
78
原创 Dialog
Base class for Dialogs.#子类 AlertDialogA subclass of Dialog that can display one, two or three buttons. If you only want to display a String in this dialog box, use the setMessage() method.If you wa...
2019-07-16 02:05:18
435
空空如也
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人