-
cmpp源码接口实现
使用java技术,比较全面的写出CMPP协议短信接口的实现,内容比较详细,对初学者的帮助很大,对各种类和方法封装的比较完善,希望对初学者有用。
- 2022-02-15 03:46:05下载
- 积分:1
-
循迹
说明: 两路光电开关驱动,2019电赛A组,测试程序(Two-way Photoelectric Switch Drive, Group A of 2019 Electricity Competition, Test Procedure)
- 2020-06-17 16:40:02下载
- 积分:1
-
desine联系编辑
该项目使你成为好的gui desiner,在你了解想要学习它,将有助于更好的克服desining问题
- 2022-02-05 10:35:56下载
- 积分:1
-
InputMethodManager
For scheduling work on the main thread. This also serves as our global lock.
- 2014-02-17 14:31:35下载
- 积分:1
-
j2me 代码猎鸟飞行
Mario 基于游戏要求实现碰撞检测在 J2ME 中已经存在的库比更多的细节。例如,提供的方法只返回 true 或 false 时碰撞检测。这并没有告诉你的碰撞点,或雪碧的哪一侧碰撞发生,这是必须要告诉是否 Mario 跳上他的敌人头或者只是打他和模具。不过我们可以达到看似复杂控制算法用只是一个 if 子句。这个操作会给你一些想法有关实现这种功能。
- 2022-03-15 02:29:52下载
- 积分:1
-
网上唱片商店,javaweb练习最给力的项目
这是一个javascript 题目是网上唱片商店,能实现前台和后台的功能,包括,前台可以支付账单,选择账单,后台包括添加唱片,管理唱片,还有添加操作人员,删除操作人员,管理操作人员。同时这个也是连接数据库的,对应的是数据库里的数据,应用到的是jdbc的技术
- 2022-02-13 06:18:39下载
- 积分:1
-
Android tcp通讯学习用
核心代码:package com.Test;import android.os.Bundle;import android.os.Handler;import android.os.Message;import android.util.Log;import android.app.Activity;import android.view.Menu;import android.widget.Button;import android.view.View;import android.view.View.OnClickListener;import java.io.BufferedInputStream;import java.io.InputStream;import java.io.OutputStream;import java.io.IOException;import java.io.UnsupportedEncodingException;import java.io.InputStreamReader;import java.io.BufferedReader;import java.io.PrintWriter;import java.io.Reader;import java.net.Socket;import java.net.ServerSocket;import java.net.UnknownHostException;import android.view.TextureView;import android.widget.EditText;import java.lang.String;import java.lang.Thread;public class MainActivity extends Activity implements OnClickListener{ private Button m_btn; private Button m_sendbtn; private ServerSocket mySerSocket; private Socket clientSocket; private EditText m_edit; private String line; boolean conn = true; private Socket accSocket; private static final String Host = "10.0.2.2"; private static final int Port = 12000; @Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.activity_main); m_btn = (Button)findViewById(R.id.button1); m_sendbtn = (Button)findViewById(R.id.button2); m_edit = (EditText)findViewById(R.id.editText1); //m_btn.setOnClickListener(this); m_btn.setOnClickListener(new ReceiverListener()); m_sendbtn.setOnClickListener(this); //Socket clientSocket = new Socket(Host, Port); } class ReceiverListener implements OnClickListener { private ReceiveThread mReceiveThread = null; private boolean stop = true; private Handler mHandler = null; public void onClick(View v) { try { if(clientSocket == null) { clientSocket = new Socket(Host, Port); } // InputStream myInputStream = clientSocket.getInputStream();// // //BufferedReader in = new BufferedReader(new InputStreamReader(myInputStream));//// byte [] buffer = new byte[myInputStream.available()]; //int temp = 0; //String strMsg = in.readLine(); // myInputStream.read(buffer);// // // String strMsg = new String(buffer);// // m_edit.setText(strMsg);// while ((temp = myInputStream.read(buffer)) != -1)// {// m_edit.setText(new String(buffer, 0, temp));//// } mReceiveThread = new ReceiveThread(clientSocket); stop = false; mReceiveThread.start(); } catch (IOException e) { e.printStackTrace(); } //消息处理 mHandler = new Handler() { public void handleMessage(Message msg) { m_edit.setText((msg.obj).toString()); } }; } private class ReceiveThread extends Thread { private InputStream inStream = null; private byte[] buf; private String str = null; ReceiveThread(Socket s) { try { this.inStream = s.getInputStream(); } catch(IOException e) { e.printStackTrace(); } } public void run() { while(!stop) { this.buf = new byte[512]; try { this.inStream.read(this.buf); } catch(IOException e) { e.printStackTrace(); } try { this.str = new String(this.buf, "GB2312").trim(); } catch(UnsupportedEncodingException e) { e.printStackTrace(); } Message msg = new Message(); msg.obj = this.str; mHandler.sendMessage(msg); } } } } public void onClick(View v) {// if (v.getId() == R.id.button1)// {// new Thread()// {// public void run()// {// try // {// if(clientSocket == null)// {// clientSocket = new Socket(Host, Port);// } // InputStream myInputStream = clientSocket.getInputStream();// // BufferedReader in = new BufferedReader(new InputStreamReader(myInputStream));//// byte [] buffer = new byte[1024 * 4];//// int temp = 0;// // String strMsg = in.readLine();// // //myInputStream.read(buffer);// // //String strMsg = new String(buffer);// // m_edit.setText(strMsg);////// while ((temp = myInputStream.read(buffer)) != -1)//// {//// m_edit.setText(new String(buffer, 0, temp));//////// }// // }// catch (IOException e)// {// e.printStackTrace();// }// }// }.start();// // } if(v.getId() == R.id.button2) { new Thread() { public void run() { try { if(clientSocket == null) { clientSocket = new Socket(Host, Port); } //inputStream clientInputStream = clientSocket. String msg = "RESET-SHOW"; //InputStream clientInputStream = clientSocket.getInputStream(); //BufferedReader br = new BufferedReader(new InputStreamReader(clientSocket.getInputStream())); //BufferedReader br = new BufferedReader(); //line = br.readLine(); OutputStream clientOutputStream = clientSocket.getOutputStream(); byte buffer[]=msg.getBytes(); clientOutputStream.write(buffer); clientOutputStream.flush(); //int temp = 0; // PrintWriter out = new PrintWriter(clientOutputStream);// // out.println("Serer Message: " msg); } catch(IOException e) { e.printStackTrace(); } } }.start(); } }private Reader InputStreamReader() { // TODO Auto-generated method stub return null; }// private Handler handler = new Handler()// {// public void handleMessage(Message msg)// {// super.handleMessage(msg);// //处理UI// m_edit.setText("Finish");// Log.i("PDA", "Finish");// // }// }; @Override public boolean onCreateOptionsMenu(Menu menu) { // Inflate the menu; this adds items to the action bar if it is present. getMenuInflater().inflate(R.menu.main, menu); return true; }}
- 2014-08-18下载
- 积分:1
-
ID3决策树算法
资源描述本程序采用的是java编程实现,用来解决分类问题,使用的算法是数据挖掘中的ID3算法。该算法能够解决一些简单的分类问题,简单易懂,思路比较清晰。
- 2022-08-18 19:37:42下载
- 积分:1
-
AhHuiUniversity
随着经济与科技的快速发展,智能手机一步步进入普通人得生活,它将成为人们获取信息的主要设备,因此基于Android手机的手机地图服务需求越开越迫切,为外出旅游的人们提供了极大地便利。Android是Google开发的基于Linux平台的开源手机操作系统。它包括操作系统、中间件、用户界面和应用程序,是为移动终端打造的真正开放和完整的移动软件。本文对目前应用的Symbian、WindowsMoblie、Mac OS X和Android平台的现状进行了分析与比较,主要阐述以面向对象程序开发语言JAVA,以eclipse为开发工具,基于智能手机Android之上设计一个导览系统。本文主要介绍安徽大学,界面友好 、操作便捷,具有良好的可扩展性和可维护性,系统经过测试,可以稳定运行,能够满足手机用户基本的地图服务需求。(With the rapid development of economy and technology,Smartphone enters into the lives of ordinary people step by step,it will become the main device to obtain information,Therefore,based on the Android mobile phone mobile map service needs become more and more urgent for people who travel offers great convenience.Android is the Google development opens the source handset operating system based on Linux platform. It includes the operating system,the Middleware,he user interface and the application procedure. It is for the mobile terminal to create a truly open and complete mobile software. In this thesis,there is a analysis and comparion about the status of the current applide platforms like Symbiam ,WindowsMoblie,Mac OS X and Android ,this thesis Mainly expounds the development of object-oriented programming language java, eclipse as a
development tool, to design a navigation system-based smartphone on Android. This paper mainly introduces the anhui university,user-friendly,easy to)
- 2013-10-30 13:56:55下载
- 积分:1
-
interview-questions-from-shanghai
android开发工程师的面试题库,主要来自于上海地区,找工作的朋友可以看看(interview questions from shanghai)
- 2013-08-12 03:44:31下载
- 积分:1