Mercurial > hg > Database > Alice
view src/main/java/alice/topology/manager/keeparive/TaskInfo.java @ 345:8f71c3e6f11d
Change directory structure Maven standard
author | sugi |
---|---|
date | Wed, 16 Apr 2014 18:26:07 +0900 |
parents | |
children | aefbe41fcf12 |
line wrap: on
line source
package alice.topology.manager.keeparive; public class TaskInfo { private TaskType type; private long sleepTime; private String managerKey; private String returnKey; public TaskInfo(TaskType t){ type = t; } public void setInfo(String managerKey, long time){ this.managerKey = managerKey; sleepTime = time; } public void setInfo(String managerKey, String returnKey, long time){ this.managerKey = managerKey; this.returnKey = returnKey; sleepTime = time; } public TaskType getType(){ return type; } public long getSleepTime(){ return sleepTime; } public void setSleepTime(long time){ sleepTime = time; } public String getManagerKey(){ return managerKey; } public String getReturnKey(){ return returnKey; } public TaskInfo clone(){ TaskInfo task = new TaskInfo(type); task.setInfo(managerKey, returnKey, sleepTime); return task; } public void show(){ System.out.print(type); System.out.print(" "+ this.sleepTime); System.out.print(" "+ this.managerKey); System.out.println(" "+ this.returnKey); } }