📄 sender.java~3~
字号:
package fourconnect;/** * <p>Title: </p> * <p>Description: </p> * <p>Copyright: Copyright (c) 2006</p> * <p>Company: </p> * @author not attributable * @version 1.0 */import java.io.*;import javax.microedition.io.*;import javax.microedition.lcdui.*;import javax.microedition.midlet.*;public class Sender extends Thread { public OutputStream out; public static String message; Thread thread; public Sender(OutputStream out) { this.out=out; start(); } public void start(){ thread =new Thread(this); thread.start(); } public static void send(String sendstring){ message=sendstring; // notify(); } public void run(){ while(gamecanvas.isgame){ try{ if(message==null){ try{ // wait(); }catch(Exception e){System.out.println("000000");} } //if(message==null)break; try{ out.write(message.getBytes()); out.write("\n".getBytes()); }catch(Exception e){System.out.println("1111111");} message=null; }catch(Exception e){System.out.println("send errir");} } }}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -