Railway Document
-
Upload
priya-guna -
Category
Documents
-
view
216 -
download
0
Transcript of Railway Document
-
8/2/2019 Railway Document
1/28
-
8/2/2019 Railway Document
2/28
2.1 PROJECT INTRODUCTION:
This project introduces railway reservation system. It explains how reservation is
being done in Indian Railways. The step by step procedure is explained. This project is
developed in Java language. All most all the header files have been used in this project.
Proper comments have been given at desired locations to make the project user friendly.
Various functions and structures are used to make a complete use of this language.
This project is well versed with the programming. Railway reservation can easily
accompany with the help of this. This project involves computerization of entire agency,
when some one comes to enquire about the details of the Reservation; we have to collect
the information about them. A particular code number is given to them and this code
number is used for all the further transactions for the customers.
Our primary objectives are:
To be honest and fair in all our dealings
To be committed to properly and promptly addressing customer needs
To treat our clients' needs as if they were our own
To remain open and understanding to all issues and concerns
To always be the kind of people upon which you can depend
-
8/2/2019 Railway Document
3/28
2.2 Language Introduction:
INTRODUCTION TO JAVA
Java is a new computer programming language developed by Sun Microsystems in
1996 by. Java has a good chance to be the first really successful new computer language in
several decades. Advanced programmers like it because it has a clean, well-designed
definition. Business likes it because it dominates an important new application, Web
programming.
Java has several important features
A Java program runs exactly the same way on all computers. Most other languages
allow small differences in interpretation of the standards.
It is not just the source that is portable. A Java program is a stream of bytes that
can be run on any machine. An interpreter program is built into Web browsers,
though it can run separately. Java programs can be distributed through the Web to
any client computer.
Java applets are safe. The interpreter program does not allow Java code loaded
from the network to access local disk files, other machines on the local network, or
local databases. The code can display information on the screen and communicate
back to the server from which it was loaded.
A group at Sun reluctantly invented Java when they decided that existing computer
languages could not solve the problem of distributing applications over the network. C++
inherited many unsafe practices from the old C language. Basic was too static and
constrained to support the development of large applications and libraries.
Today, every major vendor supports Java. Netscape incorporates Java support in
every version of its Browser and Server products. Oracle will support Java on the Client,
the Web Server, and the Database Server. IBM looks to Java to solve the problems caused
by its heterogeneous product line.
-
8/2/2019 Railway Document
4/28
The Java programming language and environment is designed to solve a number of
problems in modern programming practice. It has many interesting features that make it an
ideal language for software development. It is a high-level language that can be
characterized by all of the following buzzwords:
Features
Sun describes Java as
Simple
Object-oriented
Distributed
Robust
Secure
Architecture Neutral
Portable
Interpreted
High performance
Multithreaded
Dynamic.
Java is simple
What it means by simple is being small and familiar. Sun designed Java as closely
to C++ as possible in order to make the system more comprehensible, but removed many
rarely used, poorly understood, confusing features of C++. These primarily include
operator overloading, multiple inheritance, and extensive automatic coercions. The mostimportant simplification is that Java does not use pointers and implements automatic
garbage collection so that we don't need to worry about dangling pointers, invalid pointer
references, and memory leaks and memory management.
-
8/2/2019 Railway Document
5/28
Java is object-oriented
This means that the programmer can focus on the data in his application and the
interface to it. In Java, everything must be done via method invocation for a Java object.
We must view our whole application as an object; an object of a particular class.
Java is distributed
Java is designed to support applications on networks. Java supports various levels
of network connectivity through classes in java.Net. For instance, the URL class provides
a very simple interface to networking. If we want more control over the downloading data
than is through simpler URL methods, we would use a URLConnection object which is
returned by a URL.openConnection () method. Also, you can do your own networking with
the Socket and Server Socket classes.
Java is robust
Java is designed for writing highly reliable or robust software. Java puts a lot ofemphasis on early checking for possible problems, later dynamic (runtime) checking, and
eliminating situations that are error prone. The removal of pointers eliminates the
possibility of overwriting memory and corrupting data.
Java is secure
Java is intended to be used in networked environments. Toward that end, Java
implements several security mechanisms to protect us against malicious code that might try
to invade your file system. Java provides a firewall between a networked application and
our computer.
-
8/2/2019 Railway Document
6/28
Java is architecture-neutral
Java program are compiled to an architecture neutral byte-code format. The
primary advantage of this approach is that it allows a Java application to run on any system
that implements the Java Virtual Machine. This is useful not only for the networks but also
for single system software distribution. With the multiple flavors of Windows 95 and
Windows NT on the PC, and the new PowerPC Macintosh, it is becoming increasing
difficult to produce software that runs on all platforms.
Java is portable
The portability actually comes from architecture-neutrality. But Java goes even
further by explicitly specifying the size of each of the primitive data types to eliminate
implementation-dependence. The Java system itself is quite portable. The Java compiler is
written in Java, while the Java run-time system is written in ANSI C with a clean
portability boundary.
Java is interpreted
The Java compiler generates byte-codes. The Java interpreter executes the
translated bytecodes directly on system that implements the Java Virtual Machine. Java's
linking phase is only a process of loading classes into the environment.
Java is high-performance
Compared to those high-level, fully interpreted scripting languages, Java is high-
performance. If the just-in-time compilers are used, Sun claims that the performance of
byte-codes converted to machine code are nearly as good as native C or C++. Java,
however, was designed to perform well on very low-power CPUs.
Java is multithreaded
-
8/2/2019 Railway Document
7/28
Java provides support for multiple threads of execution that can handle different
tasks with a Thread class in the java.lang Package. The thread class supports methods to
start a thread, run a thread, stop a thread, and check on the status of a thread. This makes
programming in Java with threads much easier than programming in the conventional
single-threaded C and C++ style.
Java is dynamic.
Java language was designed to adapt to an evolving environment. It is a more
dynamic language than C or C++. Java loads in classes, as they are needed, even from
across a network. This makes an upgrade to software much easier and effectively. With
the compiler, first we translate a program into an intermediate language called Javabytecodes ---the platform-independent codes interpreted by the interpreted on the Java
platform. The interpreter parses and runs each Java bytecode instruction on the computer.
Compilation happens just once; interpretation occurs each time the program is executed.
Java byte codes can be thought as the machine code instructions for the Java Virtual
Machine (JVM). Every Java interpreter, whether its a development tool or a web browser
that can run applets, is an implementation of the Java Virtual Machine.
2.3.2 The Java Platform
A platform is the hardware or software environment in which a program runs. Most
Platforms can be described as a combination of the operating system and hardware. The
Java platform differs from most other platforms in that its software only platform that
runs on top of other hardware-based platforms.
The Java platform has two components:
. The Java Virtual Machine (JVM).
2. The Java Application Programming Interfaces (Java API).
The JVM has been explained above. Its the base for the Java platform and is
ported onto various hardware-based platforms.
-
8/2/2019 Railway Document
8/28
The Java API is a large collection of ready-made software components that provide
many useful capabilities, such as graphical user interface (GUI). The Java API is grouped
into libraries of related classes and interfaces; these libraries are known as packages.
Native code is code that after you compile it, the compiled code runs on a specific
hardware platform. As a platform-independent environment, the Java platform can be bit
slower than native code. However, smart compilers, well-tuned interpreters, and just-in-
time bytecode compilers can bring performance close to that of native code without
threatening portability.
Overview of the Swing
The Swing package is part of Java Foundation Classes (JFC) in the Java platform.
The JFC encompasses a group of features to help people build GUIs; Swing provides all
the components from buttons to split panes and tables.
The Swing package was first available as an add-on to JDK 1.1. Prior to the
introduction of the Swing package, the Abstract Window Toolkit (AWT) components
provided all the UI components in the JDK1.0 and 1.1 platforms. Although the Java2
Platform still supports the AWT components, we strongly encourage using Swing
components instead. You can identify Swing components because their names start with J.
The AWT button class, for example, is named Button, whereas the Swing button class is
named JButton. In addition, the AWT components are in the java.awt package, whereas the
swing components are in the javax.swing package.
As a rule, programs should not use heavyweight AWT components alongside
Swing components. Heavyweight components include all the ready-to-use AWT
components, such as Menu and Scroll Pane, and all components that inherit from the AWT
canvas and Panel classes. When Swing components (and all other lightweight
-
8/2/2019 Railway Document
9/28
components) overlap with heavyweight components, the heavyweight component is always
painted on top.
Swing Features and Concepts
It introduces Swings features and explains all the concepts we need to be able to
use Swing components effectively.
Swing Components and the Containment Hierarchy
Swing provides many standard GUI components such as buttons, lists, menus and
text areas, which we combine to create our programs GUI. It also includes containers
such as windows and tool bars.
Layout Management
Containers use layout managers to determine the size and position of the
components they contain. Borders affect the layout of Swing GUIs by making Swing
components larger. We can also use invisible components to affect layout.
Event Handling
Event handling is how programs respond to external events, such as the user
pressing a mouse button. Swing programs perform all their painting and event handling in
the event-dispatching thread.
Painting
Painting means drawing the components on-screen. Although its easy to customize
a components painting, most programs dont do anything more complicated than
customizing a components border.
Threads and Swing
-
8/2/2019 Railway Document
10/28
If we do something to a visible component that might depend on or affect its state,
then we need to do it from the event-dispatching thread. This isnt an issue for many
simple programs, which generally refer to components only in event -handling code.
However, other programs need to use the invoke Later method to execute component-
related calls in the event-dispatching thread.
More Swing Features and Concepts
These are some of the major concepts we need to know to build Swing GUIsthe
containment hierarchy, layout management, event handling, painting, and threads. These
are some of the other important Swing features. They are
Features that JComponent provides
Icons
Actions
Pluggable Look and Feel support
Support for assistive technologies
Separate data and state models
Features that JComponent Provides
Except for the top-level containers, all components that begin with J inherit from
the JComponent class. They get many features from JComponent, such as the ability to
have borders, tool tips, and a configurable look and feel. They also inherit many
convenient methods.
Icons
Many Swing componentsnotably buttons and labelscan display images. We
specify these images as Icon objects.
Actions
-
8/2/2019 Railway Document
11/28
With Action objects, the Swing API provides special support for sharing data and
state between two or more components that can generate action events. For example, if we
have a button and a menu item that perform the same function, consider using an action
object to coordinate the text, icon, and enabled state for the two components.
Pluggable Look and Feel
This Feature enables the user to switch the look- and-feel of Swing components
without restarting the application. The Swing library supports cross-platform look-and-
feel---also Java look-and-feel--- that remains the same across all platforms wherever the
program runs. The native look-and-feel is native to whatever particular system on which
the program happens to be running, including Windows and Motif. The Swing library
provides an API that gives great flexibility in determining the look-and-feel of applications.
It also enables you to create our own look-and-feel.
Support for Assistive Technologies
Assistive technologies such as screen readers can use the Accessibility API to get
information from swing components. Because support for the Accessibility API is built
into the Swing components, our swing program will probably work just fine with assistive
technologies, even if we do nothing special.
Separate Data and State Models
Most non container Swing components have models. A button (JButton), for
example, has a model (ButtonModel) that stores the buttons statewhat its keyboard
mnemonic is, whether its enabled, selected, or pressed, and so on.
Some components have multiple models. A list (JList), for example, uses a
ListModel to hold the lists contents, and a ListSelectionModel to track the lists current
Selection.
-
8/2/2019 Railway Document
12/28
-
8/2/2019 Railway Document
13/28
The existing system is used manual. The user has been maintaining files, ledgers
and Entry book for entering details. Maintaining the data manually is a tedious job. All the
calculations must be done manually.
The users are interested to speed up the calculations and to rectify the errors.
Existing system is the manual one which has the following drawbacks.
Limitations
Much time is wasted in entering the details.
Lot of information cannot be stored in the files.
It requires more space& more time for maintaining the files.
Required information cannot be retrieved easily. So the desire for the development
of the proposed system had become essential.
Propose System:
Today one cannot afford to rely on the fallible human beings of be really wants to
stand against todays merciless competition where not to wise saying to err is human no
longer valid, its outdated to rationalize your mistake. So, to keep pace with time, to bring
about the best result without mal functioning and greater efficiency so to replace the
unending heaps of flies with a much sophisticated hard disk of the computer. One has to
use the data management software. Software has been an ascent in atomization various
organizations. Many software products working are now in markets, which have helped in
making the organizations work easier and efficiently. Data management initially had to
maintain a lot of ledgers and a lot of paperwork has to be done but now software product
on this organization has made their work faster and easier. Now only this software has to
be loaded on the computer and work can be done. This prevents a lot of time and money.
The work becomes fully automated and any information regarding the organization can be
obtained by clicking the button. Moreover, now its an age of computers of and automating
such an organization gives the better look.
3. System Specification:
-
8/2/2019 Railway Document
14/28
-
8/2/2019 Railway Document
15/28
Customer details
Reservation details
Schedule details
Cancellation
MODULE DESCRIPTION:
LOGIN:
This is used to verify the user is valid or not. It helps in preventing unauthorized user
accessing the information.
CUSTOMER DETAILS:
This is used to maintain all details about the passenger who are going to reserve for airway.
All the details will be maintained in database and it can be retrieved whenever needed.
RESERVATION DETAILS:
This module contains all information about the passenger who reserved for Train. It
contains passenger information with additional Train details.
SCHEDULE DETAILS:
It contain all Train information which is to be stored in database. It contain fields such as
Train name, number, code, from, to etc. Corresponding information can be displayed in
data grid
5. Data Flow Diagram:
-
8/2/2019 Railway Document
16/28
6. SYSTEM DESIGN
FUNDAMENTALS OF DESIGN CONCEPTS
-
8/2/2019 Railway Document
17/28
INPUT DESIGN
Input design is the process of converting the user-oriented. Input to a computer
based format. The goal of the input design is to make the data entry easier , logical and free
error. Errors in the input data are controlled by the input design. The quality of the input
determines the quality of the system output.
All the data entry screen are interactive in nature, so that the user can directly enter
into data according to the prompted messages. The user are also can directly enter into data
according to the prompted messages. The users are also provided with option of selecting
an appropriate input from a list of values. This will reduce the number of error, which are
otherwise likely to arise if they were to be entered by the user itself.
Input design is one of the most important phase of the system design. Input design
is the process where the input received in the system are planned and designed, so as to get
necessary information from the user, eliminating the information that is not required. The
aim of the input design is to ensure the maximum possible levels of accuracy and also
ensures that the input is accessible that understood by the user.
OUTPUT DESIGN
-
8/2/2019 Railway Document
18/28
Output design is very important concept in the computerized system, without
reliable output the user may feel the entire system is unnecessary and avoids using it. The
proper output design is important in any system and facilitates effective decision-making.
The output design of this system includes various reports.
Computer output is the most important and direct source of information the user.
Efficient, intelligible output design should improve the systems relationships with the user
and help in decision making. A major form of output is the hardcopy from the printer.
Output requirements are designed during system analysis. A good starting point for
the output design is the data flow diagram. Human factors reduce issues for design
involved addressing internal controls to ensure readability.
An application is successful only when it can provide efficient and effective reports.
Reports are actually presentable form of the data. The report generation should be useful to
the management for future reference. The report are the main source of information for
users operators and management. Report generated are a permanent record of the
transaction occurred. After any valid transactions; have commenced the report of the same
are generation and: filed for future reference. Great care has been taken when designation
the report as it plays an important role in decision-marking.
7. Sample Code and Design:
-
8/2/2019 Railway Document
19/28
8. SYSTEM TESTING & IMPLEMENTATION
SYSTEM TESTING
-
8/2/2019 Railway Document
20/28
System testing of software is testing conducted on a complete, integrated system to
evaluate the system's compliance with its specified requirements. System testing falls
within the scope ofblack box testing, and as such, should require no knowledge of the
inner design of the code or logic.
As a rule, system testing takes, as its input, all of the "integrated" software
components that have successfully passed integration testing and also the software system
itself integrated with any applicable hardware system(s). The purpose of integration testing
is to detect any inconsistencies between the software units that are integrated together
(called assemblages) or between any of the assemblages and the hardware. System testing
is a more limiting type of testing; it seeks to detect defects both within the "inter-
assemblages" and also within the system as a whole.
Unit Test
The first test in the development process is the unit test. The source code is
normally divided into modules, which in turn are divided into smaller units called units.
These units have specific behavior. The test done on these units of code is called unit test.
Unit test depends upon the language on which the project is developed. Unit tests ensure
that each unique path ofthe project performs accurately to the documented specifications
and contains clearly defined inputs and expected results.
Integration testing:-
Integration Testing addresses the issues associated with the dual problems of
verification and program construction. After the software has been integrated a set of High-
http://en.wikipedia.org/wiki/Requirementshttp://en.wikipedia.org/wiki/Requirementshttp://en.wikipedia.org/wiki/Black_box_testinghttp://en.wikipedia.org/wiki/Integration_testinghttp://en.wikipedia.org/wiki/Black_box_testinghttp://en.wikipedia.org/wiki/Integration_testinghttp://en.wikipedia.org/wiki/Requirements -
8/2/2019 Railway Document
21/28
order tests are conducted. The main objective in this testing process is to take unit-tested
modules and build a program structure that has been dictated by design.
The following are the types of Integration Testing:
i) Top-Down Integration
This method is an incremental approach to the construction of program structure.
Modules are integrated by moving downward through the control hierarchy, beginning with
the main program module. The module subordinates to the main program module are
incorporated into the structure in either a depth first of breadth-first manner.
ii) Bottom-Up Integration
This method begins the construction and testing with the modules at the lowest
level in the program structure. Since the modules are integrated from the bottom up,
processing required for modules subordinate to a given level is always available and the
need fro stubs is eliminated. The bottom-up integration strategy may be implemented with
the following steps :
The low level modules are combined into clusters that perform a specific
software sub-function.
A driver(i.e.),the control program for testing is written to co-ordinate test case
input and output.
The cluster is tested.
Drivers are removed and clusters are combined moving upward in the program
structure.
-
8/2/2019 Railway Document
22/28
Black box testing
This method treats the code module as a black box. The module is run with inputs
that are likely to cause errors. Then the output is checked to see if any errors occurred.
However, this method cannot be used to test all errors, because some errors may depend on
the code or algorithm used to implement the module.
Black box testing implies that the selection of test data as well as the interpretation
of test results are performed on the basis of the functional properties of a piece of software.
Black box testing should not be performed by the author of the program who knows too
much about the program internals. In new testing approaches, software systems are given a
third external party for black box testing after having successfully finished the internal
glass box testing exercises.
White box testing
White box testing strategy deals with the internal logic and structure of the code.
White box testing is also called as glass, structural, open box or clear box testing. The tests
written based on the white box testing strategy incorporate coverage of the code written,
branches, paths, statements and internal logic of the code etc.
In order to implement white box testing, the tester has to deal with the code and
hence is needed to possess knowledge of coding and logic i.e. internal working of the code.
White box test also needs the tester to look into the code and find out which
unit/statement/chunk of the code is malfunctioning.
Using white box testing method, the software engineer can drive cases that
1) Guarantee that all independent paths within a module have been exercised at least once.
2) Exercise all logical divisions on their true and false sides.
-
8/2/2019 Railway Document
23/28
3) Exercise all loops at their boundaries and within their operational bounds.
4) Exercise internal data structures to ensure their validity.
Validation testing
At the end of Integration Testing, software is completely assembled as a package,
interfacing errors have been uncovered and correction testing begin.
Validation Test Criteria:
Software Testing and Validation is achieved through serried of black box tests that
demonstrate conformity with the requirements. A test plan outlines the classes of tests to be
conducted and a test procedure defines specific test cases that will be used to demonstrate
conformity with requirements. Both, the plan and the procedure are designed to ensure that
all functional requirements are achieved, documentation is correct and other requirements
are met.
10 SYSTEM IMPLEMENTATION
The purpose ofSystem Implementation can be summarized as follows:
It making the new system available to a prepared set of users (the deployment), and
positioning on-going support and maintenance of the system within the Performing
-
8/2/2019 Railway Document
24/28
Organization (the transition). At a finer level of detail, deploying the system consists of
executing all steps necessary to educate the Consumers on the use of the new system,
placing the newly developed system into production, confirming that all data required at
the start of operations is available and accurate, and validating that business functions that
interact with the system are functioning properly. Transitioning the system support
responsibilities involves changing from a system development to a system support and
maintenance mode of operation, with ownership of the new system moving from the
Project Team to the Performing Organization.
List of System implementation is the important stage of project when the theoretical design
is tuned into practical system. The main stages in the implementation are as follows:
Planning
Training
System testing and
Changeover Planning
Planning is the first task in the system implementation. Planning means deciding on
the method and the time scale to be adopted. At the time of implementation of any system
people from different departments and system analysis involve. They are confirmed to
practical problem of controlling various activities of people outside their own data
processing departments. The line managers controlled through an implementation
coordinating committee. The committee considers ideas, problems and complaints of user
department, it must also consider;
The implication of system environment
Self selection and allocation form implementation tasks
Consultation with unions and resources available
-
8/2/2019 Railway Document
25/28
Standby facilities and channels of communication
The following roles are involved in carrying out the processes of this phase. Detailed
descriptions of these roles can be found in the Introductions to Sections I and III.
_ Project Manager
_ Project Sponsor
_ Business Analyst
_ Data/Process Modeler
_ Technical Lead/Architect
_ Application Developers
_ Software Quality Assurance (SQA) Lead
_ Technical Services (HW/SW, LAN/WAN, TelCom)
_ Information Security Officer (ISO)
_ Technical Support (Help Desk, Documentation, Trainers)
_ Customer Decision-Maker
_ Customer Representative
_ Consumer
The purpose ofPrepare for System Implementation is to take all possible steps to
ensure that the upcoming system deployment and transition occurs smoothly, efficiently,
and flawlessly. In the implementation of any new system, it is necessary to ensure that the
Consumer community is best positioned to utilize the system once deployment efforts have
been validated. Therefore, all necessary training activities must be scheduled and
coordinated. As this training is often the first exposure to the system for many individuals,
-
8/2/2019 Railway Document
26/28
it should be conducted as professionally and competently as possible. A positive training
experience is a great first step towards Customer acceptance of the system.
During System Implementation it is essential that everyone involved be absolutely
synchronized with the deployment plan and with each other. Often the performance of
deployment efforts impacts many of the Performing Organizations normal business
operations. Examples of these impacts include:
_Consumers may experience a period of time in which the systems that they depend on to
perform their jobs are temporarily unavailable to them. They may be asked to maintain
detailed manual records or logs of business functions that they perform to be entered into
the new system once it is operational.
_ Technical Services personnel may be required to assume significant implementation
responsibilities while at the same time having to continue current levels of service on other
critical business systems.
_Technical Support personnel may experience unusually high volumes of support
requests due to the possible disruption of day-to-day processing.
Because of these and other impacts, the communication of planned deployment
activities to all parties involved in the project is critical. A smooth deployment requires
strong leadership, planning, and communications. By this point in the project lifecycle, the
team will have spent countless hours devising and refining the steps to be followed. During
this preparation process the Project Manager must verify that all conditions that
must be met prior to initiating deployment activities have been met, and that the final
green light is on for the team to proceed. The final process within the System
Development Lifecycle is to transition ownership of the system support responsibilities to
-
8/2/2019 Railway Document
27/28
the Performing Organization. In order for there to be an efficient and effective transition,
the Project Manager should make sure that all involved parties are aware of the transition
plan, the timing of the various transition activities, and their role in its execution.
Due to the number of project participants in this phase of the SDLC, many of the
necessary conditions and activities may be beyond the direct control of the Project
Manager. Consequently, all Project Team members with roles in the implementation efforts
must understand the plan, acknowledge their responsibilities, recognize the extent to which
other implementation efforts are dependent upon them, and confirm their commitment.
11. Conclusions:
Now one can easily plan the journey comfortably as the process is efficient and fast
with Being easy to access. Reservations can be made through the Indian railways site or at
the ample reservation centers all over the country. Also now there are authorized agencies
which provide reservation facility on be half of India railways and without waiting in long
line one can easily book a ticket. The booking is done through an E-Ticket issue which has
a PNR number of which one has to take a print and just have to show at the station. It not
only provides reservation but cancellation can also be done through this system at ease and
one can use a credit card to complete the process. This being a big step in terms of
improvement in the railway system it is widely accepted across the country.
-
8/2/2019 Railway Document
28/28