Top Banner
53

Project 1

Sep 15, 2015

Download

Documents

maanassiraj

t
Welcome message from author
This document is posted to help you gain knowledge. Please leave a comment to let me know what you think about it! Share it to your friends and learn new things together.
Transcript

I. SYSTEM SPECIFICATION AT A GLANCE

INTRODUCTIONThis programe is designed to display flight details. The programme also assists users to book and cancel flight tickets. The programe for this project makes extensive use of several features of C ++ including classes, nested classes, files user defined functions and algorithmic programming.The quintessential purpose of this project is to enable easier and more efficient access and tracking of flight details by the system. Just as in airport, all changes, updates and transactions are automated, this programme tries to mimic all behind the scenes flight transactions in a real time airport.OBJECTS STORED IN FILE :AEROPLANESPERSONS (INSIDE RESPECTIVE AEROPLANCE OBJECTS)ClassesThis programme uses object oriented programming to work with two main classes to achieve the required objective of creating a program to enable AIRLINE RESERVATION to its user. The classes are ,1. PERSON2. AEROPLANCENESSTED CLASSES : An important feature of this programme is that it uses nested classes efficiently to encapsulate different kinds of data.

ModulesModules of this project deal with : Accepting flight details from airport authority/ qualified personnel Booking a ticket Accepting details of person in whose name ticket will be booked Making changes /editing ticket Deleting tickets Viewing ticket details Searching for flights to certain destination Searching for flights from a certain destination Booking tickets over cancelled tickets in case flight is fullThe project will be divided in various modules to enable easier understanding of the source code. To enable manageable project, the project will be divided into carious classes in terms of the destinations connecting the FROM place. For e.g if the buser wants to book a ticket from Bangalore to Delhi, then classes will be extracted from the file and all the details of the available flights to Delhi will be displayed with their time of departure and time of arrival. Thus, passenger can make an informed decision.Each object will be assigned one city which will match with the TO city and give all the flights, date of journey, time of departure, time of arrival, number of seats available and the fare of each ticket. It will then give an option of confirming the tickets.

To confirm a ticket, a function will be invoked which will take in the details of person(s), like the name, age, etc. and will then calculate the fare, and finally give the ticket.

Another module will enable the user to cancel any tickets booked already. Another module will give the scheduled flights, flights capacity, all the details of the passengers and can also update the user about all the changes in the scheduled flights of the day. These include any delay of the flight departure, or any cancellations of the flight. Changes in the flight timings and other specifications of the air traffic schedule can be made on demand and will be taken care of by a function that performs this specific task, thus keeping the data files updated.An important feature of this programme is that it allows the airport management system to reallocate a cancelled ticket to the next buyer of a ticket on that flight.FilesSince all objects of person clases are within an aeroplane class, file management is simplified using a single file. Data is also retrieved easily. Functions of each class as well as fstream class work together to retrieve data. There is adequate scope for the modification of flight schedule using these functions.

NAME OF FILE USED AO.DATOBJECTS STORED IN FILE :1. AEROPLANES2. PERSONS (INSIDE RESPECTIVE AEROPLANE OBJECTS)

REQUIREMENT ANALYSISThis following hardware and software requirements must be met in order to successfully run the program.INPUTS AND OUTPUTS:A keyboard is required which allows the user to enter characters, digits and symbols through the inputstream into the program allowing the user to interact with the program.A monitor or VDU (Visual Display Unit) is required displays the results of programs through the outputstream so that the user can see them and hence interact with the program.HARDWARE REQUIREMENTS: Processor : Intel Pentium 4 CPU

CPU speed: 2.67 GHz

RAM: 512 MB

Hard disk memory : 80GB

Cache : 512 KB

SYSTEM SOFTWARE REQUIREMENTS: Operating System : Microsoft Windows XP Professional version 2002

Software : Turbo C++ IDE

III SYSTEM SPECIFICATIONSa.System DesignThe system is designed to enter all flight details like Carrier name, flight number, arrival time and departure time. The system is built to capture personal details of the passengers and book flight tickets. It is assumed that only administrator of the system will be using the system for all the functionaries like entering the flight details, booking tickets etc. It is designed to work on all systems with Windows OS2000/XP. It is designed to be a single user system. The validation of the system is done through the testing of the system.

The Object oriented programming Concepts have been used for the development of the system. The coding is done using C++ and the approach used is filed based approach.

b.Data Design

Ifstream and Ofstream class have been used to capture and store all the details of the system like passenger details, Flight details etc.

IV. C++OVERVIEW

C++ is statically typed, free-form, multi-purpose, compiled, general purpose programming language. It is regarded as an intermediate-lvel language, as it comprises a combination of both high-lvel and low-level language features. Developed by Bjarne Stroustrup starting in 1979 at Bell Labs, it adds object oriented features, such as classes, and other enhancements to the C programming language. Originally named C with Classes, the language was renamed C++ in 1983.

C++ is one of the most popular programming languages and is implemented on a wide variety of hardware and operating system platforms. As an efficient compiler to native code, its application domains include systems software, application software, device drivers, embedded software, high-performance server and client applications, and entertainment software such as video games. Several groups provide both free and proprietary C++ compiler software, including the GNU Project, Microsoft, Intel and Embarcadero Technologies. C++ has greatly influenced many other popular programming languages, most notably C# and Java. Other successful languages such as Objective-C use a very different syntax and approach to adding classes to C.

C++ is also used for hardware design, where the design is initially described in C++, then analyzed, architecturally constrained and scheduled to create a register-transfer level hardware description language via high-level synthesis.Standard template library (STL)The STL provides a ready-made set of common classes for C++, such as containers and associative arrays, that can be used with any built-in type and with any user-defined type that supports some elementary operations (such as copying and assignment). STL algorithms are independent of containers, which significantly reduces the complexity of the library.Standard LibraryThe C++ standard library incorporates the C Standard library with some small modifications to make it optimized with the C++ language. Another large part of the C++ library is based on the STL. This provides such useful tools as containers for example vectors and lists), to provide these containers with array like access and algorithms to perform operation such as searching and sorting. Furthermore (multi) maps (associative arrays) and (multi) acts are provided, all of which expert compatible interfaces. There is it possible, using templates, to write general algorithms that work with any container or on any sequence defined by iterators. As in C, the features of the library are accessed by using the directive to include a standard header. C++ provides 105 standard headers, of which 27 are deprecated.

Language featuresC++ inherits most of Cs syntax. The following is Bjarne Stroustrups version of the Hello world programme that uses the C++ Standard Library stream facility to write a message to standard output.# includeInt main (){Std::cout28)v=0;}return v;}

int validint(){int x;l1:f=0;cin>>a;for(int i=0;i