Changes between Version 1 and Version 2 of Old/Documentation/OTG/FuncSpec/OtrMainProgram
- Timestamp:
- Oct 6, 2005, 6:43:22 PM (19 years ago)
Legend:
- Unmodified
- Added
- Removed
- Modified
-
Old/Documentation/OTG/FuncSpec/OtrMainProgram
v1 v2 42 42 As can be seen, this is a very clean and short program. I explain it in detail. 43 43 44 1. First an [source:otg/trunk/src/cpp/orbitappt.h#latest OrbitApp] object is created dto handle all OML-related stuff.44 1. First an [source:otg/trunk/src/cpp/orbitappt.h#latest OrbitApp] object is created to handle all OML-related stuff. 45 45 1. Parsing user command-line input to determine 46 46 1. protocol type … … 50 50 1. Conduct 2nd-tier parse to get all detail parameters of Gate such as receiving port. 51 51 1. Init Gate 52 1. Create a sep erate thread to let Gate start receiving packets.53 1. An eternal while loop is act ting as the continuing main thread to handle run-time user inputs.52 1. Create a separate thread to let Gate start receiving packets. 53 1. An eternal while loop is acting as the continuing main thread to handle run-time user inputs. 54 54 55 55 === Discussion === 56 It is possible to have multiple gates in one OTR application. More gates ,listening to more ports and we could create more threads. But it seems there is no need to do this. Users care more than lower-layer link performance than have multiple competitive applications running on one single port.56 It is possible to have multiple gates in one OTR application. More gates listening to more ports and we could create more threads. But it seems there is no need to do this. Users care more than lower-layer link performance than have multiple competitive applications running on one single port. 57 57 58 58