Mercurial > hg > Database > Christie
changeset 242:faff3236236d
tweak
author | ichikitakahiro <e165713@ie.u-ryukyu.ac.jp> |
---|---|
date | Thu, 23 Jan 2020 01:06:29 +0900 |
parents | dc76dd99eebb |
children | 9d0b932ad84f |
files | src/main/java/christie/remoteTextEditor/CheckCommand.java src/main/java/christie/remoteTextEditor/CheckMyName.java src/main/java/christie/remoteTextEditor/RemoteNodeStart.java src/main/java/christie/remoteTextEditor/StartRemotingTextEditor.java src/main/java/christie/textEditor/main.java |
diffstat | 5 files changed, 6 insertions(+), 4 deletions(-) [+] |
line wrap: on
line diff
--- a/src/main/java/christie/remoteTextEditor/CheckCommand.java Thu Jan 23 00:56:38 2020 +0900 +++ b/src/main/java/christie/remoteTextEditor/CheckCommand.java Thu Jan 23 01:06:29 2020 +0900 @@ -21,7 +21,7 @@ if(myEditor.checkPermission() == true) { Command cmd = new Insert(myEditor.returnOffset(), myEditor.returnString()); myEditor.changeToFalseSendPermmision(); - put("opponent", "cmd", new Message()); + put("partner", "cmd", new Message()); System.out.println(topoDG.getNodeName() + " :catch,offset = " + myEditor.returnOffset()); // opponentは単語として不適切。
--- a/src/main/java/christie/remoteTextEditor/CheckMyName.java Thu Jan 23 00:56:38 2020 +0900 +++ b/src/main/java/christie/remoteTextEditor/CheckMyName.java Thu Jan 23 01:06:29 2020 +0900 @@ -10,10 +10,11 @@ TopologyDataGear topoDG; protected void run(CodeGearManager cgm) { - if(topoDG.getNodeName().equals("node3")){ + if(topoDG.getNodeName().equals("node0")){ cgm.setup(new StartServer()); }else{ cgm.setup(new MakeInstance()); + } } }
--- a/src/main/java/christie/remoteTextEditor/RemoteNodeStart.java Thu Jan 23 00:56:38 2020 +0900 +++ b/src/main/java/christie/remoteTextEditor/RemoteNodeStart.java Thu Jan 23 01:06:29 2020 +0900 @@ -8,6 +8,7 @@ public static void main(String[] args){ RemoteNodeConfig remoteNodeConfig = new RemoteNodeConfig(args); + StartTopologyNode startTopologyNode = new StartTopologyNode((TopologyNodeConfig) remoteNodeConfig, new CheckMyName()); }
--- a/src/main/java/christie/remoteTextEditor/StartRemotingTextEditor.java Thu Jan 23 00:56:38 2020 +0900 +++ b/src/main/java/christie/remoteTextEditor/StartRemotingTextEditor.java Thu Jan 23 01:06:29 2020 +0900 @@ -21,7 +21,7 @@ new StartTopologyManager(topologyManagerConfig); - for (int i = 0; i <= 1; i++){ + for (int i = 0; i <= 2; i++){ String[] nodeArg = {"--managerPort", String.valueOf(TopologyManagerPort), "--managerHost", "localhost", "--localPort", String.valueOf(TopologyNodePort + i),
--- a/src/main/java/christie/textEditor/main.java Thu Jan 23 00:56:38 2020 +0900 +++ b/src/main/java/christie/textEditor/main.java Thu Jan 23 01:06:29 2020 +0900 @@ -2,7 +2,7 @@ public class main { public static void main(String[] args) { - mainFrame mF = mainFrame.getInstance(); + MainFrame mF = MainFrame.getInstance(); mF.setVisible(true); } }