Add PortModules to core API #1068
Labels
Enhancement
in progress
Major Feature
A new feature that has broad impact on codebase and requires a minimum two week discussion period
Please describe the new features with any relevant use cases.
PortModules will be added to the core interfaces. The PortModule will be able to intercept Events on both send and receive.
This functionality could be useful for simulating "noisy channels", where errors may be introduced during communication.
Describe the proposed solution you plan to implement
The implementation will be similar to and encapsulate the functionality of the EventHandlerProfileTool interface (i.e., the EventHandlerProfileTool will inherit from PortModule). The major change to the API will be that the function calls will return Event* instead of void. This will allow the PortModule to modify or drop the event, if desired.
Testing plan
A test using PortModules will be developed and will test the cases of dropping and modifying Events.
Additional context
The major challenge is making the EventHandlerProfileTool inherit from both PortModule and ProfileTool. The main issue here is how to handle the ELI information for the combined class.
The text was updated successfully, but these errors were encountered: