|
EnigmaMachineCore 0.1.0
A modular Enigma Machine simulation in C++20
|
Interface for observing Enigma Machine events. Implement this interface to receive notifications about state changes. More...
#include <IEnigmaObserver.hpp>
Inheritance diagram for IEnigmaObserver:Public Member Functions | |
| virtual | ~IEnigmaObserver () |
| virtual void | onRotorStepped (int rotorIndex, AlphabetIndex position)=0 |
| Called when a rotor steps. | |
| virtual void | onCharEncrypted (char input, char output)=0 |
| Called when a character is encrypted/decrypted. | |
Interface for observing Enigma Machine events. Implement this interface to receive notifications about state changes.
Definition at line 10 of file IEnigmaObserver.hpp.
|
virtualdefault |
|
pure virtual |
Called when a character is encrypted/decrypted.
| input | The original input character. |
| output | The final output character. |
Implemented in ConsoleObserver, and EnigmaMachine.
|
pure virtual |
Called when a rotor steps.
| rotorIndex | The index of the rotor (0 is the rightmost/fastest). |
| position | The new position of the rotor (0-25). |
Implemented in ConsoleObserver, and EnigmaMachine.