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

[FEATURE] Access to Parent Source State on entry of SubState #137

Open
erikzenker opened this issue Jan 11, 2021 · 0 comments
Open

[FEATURE] Access to Parent Source State on entry of SubState #137

erikzenker opened this issue Jan 11, 2021 · 0 comments
Labels
enhancement New feature or request

Comments

@erikzenker
Copy link
Owner

Problem
The on_entry action of a state does not get the parent source state as a parameter. But the parent source state could be handy when you need to access its data members e.g. to start a timeout.

Current Workaround
Instead of storing data in the parent source state you can add additional members to the dependency struct.

Proposed Solution

Provide the parent source state to the on_entry function. The same holds true for the parent target state for the on_exit function.

@erikzenker erikzenker added the enhancement New feature or request label Jan 11, 2021
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

No branches or pull requests

1 participant