Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Design: Make different simulation specializations combinable #15

Closed
LinqLover opened this issue Mar 19, 2021 · 0 comments · Fixed by #27
Closed

Design: Make different simulation specializations combinable #15

LinqLover opened this issue Mar 19, 2021 · 0 comments · Fixed by #27
Assignees
Labels
enhancement New feature or request

Comments

@LinqLover
Copy link
Owner

The introduction of SimulationContext was important to facilitate the creation of custom context classes. Nevertheless, it's a shame that at the moment, you have to decide on one concrete subclass of SimulationContext. For example, you cannot combine the functionalities of SimulationMsrContext and SandboxContext. For further possible conflicts, refer to #14. It would be great to eliminate this limitation.

Possible approaches:

  • Composition (e.g. a subclass of SimulationContext, PluggableContext, defines hook and forwards them to a Simulator instance)
  • Chain of Responsibility vs list of simulator objects to be invoked in series ("explicit CoR")

Keep performance in mind (see #13)!

@LinqLover LinqLover added the enhancement New feature or request label Mar 19, 2021
@LinqLover LinqLover pinned this issue Mar 19, 2021
@LinqLover LinqLover self-assigned this Nov 13, 2021
LinqLover added a commit that referenced this issue Nov 13, 2021
Simulator implements the Chain of Responsibility pattern to make multiple customizations to the simulation engine combinable. Additionally, SimulationMessageSendRecorder (8f12aff) and Sandbox (fddeb9a) are ported to this new framework (for Sandbox, the new version is called Sandbox2). Tests exist as well, of course.

Closes #15.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant