Mercurial > hg > RemoteEditor > REPSessionManager
view test/mergertest/UserSimulator.java @ 502:49b689b17d06 default tip
merged TestEditor to REPEditor
author | suika6039 |
---|---|
date | Tue, 21 Dec 2010 18:01:15 +0900 |
parents | 5c95a9020e31 |
children |
line wrap: on
line source
package test.mergertest; import java.util.LinkedList; import rep.REP; import rep.REPCommand; public class UserSimulator extends Thread { private RemoteEditorSimulator editor; private LinkedList<REPCommand> userInputList; public UserSimulator(RemoteEditorSimulator editor){ this.editor = editor; int eid = editor.getEID(); userInputList = new LinkedList<REPCommand>(); int count = 0; for(int i = 0; i < 3; i++){ userInputList.add(new REPCommand(REP.REPCMD_INSERT_USER, 0, eid, count, 3, " User:" + eid + ":" + i)); count++; } } public void setUserInput(LinkedList<REPCommand> list){ userInputList = list; } @Override public void run(){ for(REPCommand command : userInputList){ editor.edit(command); } } }