Refactor and test Variable Server.

- Split VariableServerThread into VariableServerSession and VariableReference classes
- Use C++ streams for data handling
- Unit tests
This commit is contained in:
Jacqueline Deans
2022-08-23 13:47:56 -05:00
parent e89bf083b2
commit c2e42f4ef4
78 changed files with 5021 additions and 2690 deletions

View File

@ -1572,6 +1572,7 @@ public class SimControlApplication extends TrickApplication implements PropertyC
@Override
protected void finished() {
try {
System.out.println("Finished with health status socket channel");
if (healthStatusSocketChannel != null) {
healthStatusSocketChannel.close() ;
}
@ -1606,7 +1607,11 @@ public class SimControlApplication extends TrickApplication implements PropertyC
if (statusSimcom != null) {
results = statusSimcom.get().split("\t");
String resultsStr = statusSimcom.get();
if (resultsStr == null)
break;
results = resultsStr.split("\t");
ii = 1 ;
// whenever there is data in statusSimcom socket, do something

View File

@ -295,7 +295,7 @@ public class SimControlActionController {
simcom.put("trick.debug_pause_off()\n" ) ;
}
} catch (IOException e) {
System.out.println("Put failed!");
System.out.println("Put failed! Exception: " + e.getMessage());
}
}