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

More complete occurrence management. #1044

Open
gallandarakhneorg opened this issue Dec 15, 2020 · 0 comments
Open

More complete occurrence management. #1044

gallandarakhneorg opened this issue Dec 15, 2020 · 0 comments
Milestone

Comments

@gallandarakhneorg
Copy link
Member

gallandarakhneorg commented Dec 15, 2020

Several modifiers or API tools may be included in order to control the event handling.
For example:

	val uniq = new AtomicBoolean(false)
	on Ready {
		if (!this.uniq.getAndSet(true)) {
			// Do Something
		}
	}

This code enables the agent to react to Ready only for the first first time it is received.

Several ways to handle events may be:

  • react ot the first occurrence only
  • several on handlers are exclusive independently of their guards
  • following a complex interaction protocol
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

1 participant