DELAPARRA
Index
Color
NL
Category: Programming paradigms

Event

Explained by Updated

What is Event?

Event: Something that happens that the program can respond to: a button click, an HTTP request, a file change, a timer firing, a message arriving in a queue. An event is something that happens which a program can react to: a click, a key press, an incoming HTTP request, a file being saved, a timer firing or a message arriving in a queue.

Definition source Coders Lingo, CC BY 4.0

Frequently asked questions about Event

How is Event used in practice?

Event-driven code is organised around these moments. Instead of one long sequence of steps, you write small pieces of code that run when a specific event occurs.

What should you keep in mind with Event?

In web applications, events also describe business moments, such as OrderPaid or UserRegistered. Code that sends a confirmation email, updates statistics or notifies the warehouse listens for that event. The order code itself stays simple and does not need to know about all those follow-up tasks. The trade-off is that the full flow is spread out, so clear event names and a list of listeners help a lot.

At a glance

CategoryProgramming paradigms
Explained by
Updated

More Programming paradigms terms

All terms starting with E

Skills

Download all skills (zip)

Manuals

Related services

Need any help?

Stuck on one of these in your own project? Tell me what you are working on and I will tell you how I would approach it.