0% found this document useful (0 votes)
24 views2 pages

1 Removed

Uploaded by

ieshaaved
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
24 views2 pages

1 Removed

Uploaded by

ieshaaved
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 2

Case Study: Transitioning from a Procedural to Object-Oriented Model for a Student

Information System

The Student Information System is designed to manage student data efficiently, including functions like adding,
deleting, searching for students, and managing their grades and attendance records.

Procedural Approach to Managing Students

1. Data Handling:

• Student details such as name, ID, grades, and attendance are stored in separate arrays or
structures.

2. Functions:

• addStudent(): Responsible for inserting student data into arrays.


• deleteStudent(): Removes a student by searching through arrays.
• searchStudent(): Locates a student by ID or name and retrieves relevant information.
• listStudents(): Displays the current list of students in the system.

Object-Oriented Approach to Student Management

1. Classes and Objects:

• Student Class: Each student is an object with attributes such as name, ID, grades, and
attendance.
• Methods like addStudent(), deleteStudent(), and searchStudent() are encapsulated within the Student
class, ensuring all student-related operations are organized.

2. Encapsulation:

• All student data is wrapped within the object itself, reducing global data usage and improving
security.
• Access to student attributes (like grades) is controlled via methods (e.g., getGrades()).

3. Inheritance and Specialization:


• Inheritance: A parent Student class can be extended to create UndergraduateStudent and
GraduateStudent, allowing for additional functionality specific to different student types.

4. Modularity:

• Classes like Student or Course can be reused throughout the system, making it easier to extend
functionality without rewriting code.

WHY WE NEED TO MIGRATE FROM PROCEDURAL TO OBJECT ORIENTED APPROACH?

• mproved Code Organization and Structure

• Reusability and Modularity

• Ease of Maintenance and Upgrades

• Scalability and Flexibility

• Abstraction and Simplicity


• Encapsulation and Data Security

You might also like