-
Notifications
You must be signed in to change notification settings - Fork 0
SubjectOrientedProgramming
Stephen Crowley edited this page Dec 18, 2023
·
3 revisions
Subject-oriented programming is a programming paradigm that extends and varies from traditional object-oriented programming. Here are its key characteristics:
-
Subject as the Central Concept:
- The central concept in subject-oriented programming is the 'subject', akin to an object in OOP.
- Subjects are focused on specific areas or aspects of the application, encapsulating relevant data and behavior.
-
Separation of Concerns:
- This paradigm emphasizes dividing the application into distinct subjects, each responsible for a specific functionality.
- This leads to more modular and maintainable code, as each subject can be developed and understood independently.
-
Collaboration Between Subjects:
- Subjects often need to collaborate to fulfill the application’s goals.
- This is managed through well-defined interfaces, allowing for interaction without exposing internal details.
-
Composition of Behavior:
- The paradigm allows for the composition of behavior from different subjects.
- This flexibility enables mixing and matching behaviors as needed for reusable code.
-
Aspect-Oriented Programming Influence:
- Subject-oriented programming shares similarities with aspect-oriented programming (AOP), especially in separating concerns and modularizing functionalities.
Subject-oriented programming extends object-oriented concepts, focusing on dividing a program into 'subjects' that encapsulate specific functionalities or concerns. This approach enhances organization, modularity, and maintainability, particularly in complex applications.