Java多线程设计模式详解+配套源码(PDF).rar

源代码在线查看: request.java

软件大小: 10874 K
上传用户: singwolf
关键词: Java 多线程
下载地址: 免注册下载 普通下载 VIP

相关代码

				public class Request {
				    private final String name;
				    private final int number;
				    public Request(String name, int number) {
				        this.name = name;
				        this.number = number;
				    }
				    public void execute() {
				        System.out.println(Thread.currentThread().getName() + " executes " + this);
				    }
				    public String toString() {
				        return "[ Request from " + name + " No." + number + " ]";
				    }
				}
							

相关资源