Component-Based and Event-Driven Programming [Dev Concepts #6]

What is the difference between component-based and event-driven programming? Find out in this lesson!

In this tutorial, which is part of our Dev Concepts series, you will learn all about event-driven and component-based programming. 

In component-based programming, components are self-contained pieces of functionality, which are inserted as part of larger software application. Component-based software engineering is based on the composition of such reusable components.

Event-driven programming plays an important role in software components, which are typically events sources, which emit events. For example, a “button” component may emit a “button clicked” event, which is handled by the button owner.

Component events are intended to be consumed by the component owner, typically the app we are building. The event handling code for processing an event, coming from a component, is called “event handler”.

Component-based software development is a software development approach, a programming paradigm, based on the composition of reusable components.

  • Instead of building the application or system from scratch, developers take ready-to-use components and plug them into their software.
  • The components are building blocks, which come from component libraries and software packages (which can be open-source, royalty-free, or commercial).
Event-driven programming is a programming paradigm, in which the flow of the program is determined by events, such as mouse clicks, keypresses, button clicks, and many others.

Lesson Topics

In this video we review the following topics:
  • What Is Event-Driven Programming?
  • What Is Component-Based Programming?
  • Live Demo

Lesson Slides

Leave a Comment

Recent Posts

About SoftUni

SoftUni provides high-quality education, profession and job to people who want to learn coding.

The SoftUni Global “Learn to Code” Community supports learners with free learning resources, mentorship and community help.

Tags

Categories