Sei sulla pagina 1di 103

GATEDWAY COMMUNITY & SERVICES

ABSTRACT

Gated communities are neighborhoods enclosed by walls or fences, and providing services to members in that community. In those services we can provide online food services, marketing, travel agency..etc. Some gated communities may even have their own places of worship. Gated communities exist throughout the United States. Gated communities are designed to providing services and maintaining the database about the homes and apartments are located. There are a number of reasons that individuals from all walks of life may choose to live within the enclosures of a gated community. Gated communities are not reserved for the upper class and the wealthy or for the most affluent of cities. Gated communities can be found in many towns in every state. In USA Today, it was estimated that nearly seven million families lived in gated communities, and four million of these families lived in a community where it was impossible to gain access without some sort of security clearance. Residents of gated communities may own their own home, or they may rent from someone else. Residents of gated communities represent all different racial groups.

DEPT OF CSE, SMCET

GATEDWAY COMMUNITY & SERVICES

CONTENTS S. No. CHAPTER NAME 1. INTRODUCTION-----------------------------------------------------------------------7-9 1.1 1.2 1.3 1.4 1.5 MOTIVATION SCOPE OF THE SYSTEM OBJECTIVE OF PROJECT LIMITATION OF PROJECT ORGANIZATION OF DOCUMENTATION

2.LITERATURE SURVEY--------------------------------------------------------------10-12 2.1 2.2 2.3 PRESENT SITUATION WHAT WE ARE GOING TO DO WHAT WE HAVE DONE

3.SYSTEM ANALYSIS-------------------------------------------------------------------13-17 3.1 INTRODUCTION 3.2 EXISTING SYSTEM 3.3 PROPOSED SYSTEM 3.4 USER REQUIREMENTS 3.5 SOFTWARE REQUIREMENTS 3.6 HARDWARE REQUIREMENTS 3.7 FEATURES OF PROJECT 3.8 CONCLUSION 4.SYSTEM SPECIFICATION-----------------------------------------------------------18-22 4.1 4.2 INTRODUCTION FUNCTIONAL REQUIREMENTS 4.2.1 4.2.2 4.3 4.3.1 FEATURE ANALYSIS FUNCTIONAL HEIRARCHY PERFORMANCE REQUIREMENTS 2

NON-FUNCTIONAL REQUIREMENTS

DEPT OF CSE, SMCET

GATEDWAY COMMUNITY & SERVICES

4.3.2 4.3.3 4.3.4 4.4

SAFETY AND RELIABILITY SECURITY REQUIREMENTS SOFTWARE QUALITY ATTRIBUTES

CONCLUSION

5. PROJECT DESIGN------------------------------------------------------------------23-49 5.1 5.2 5.3 5.4 INTRODUCTION DATA FLOW DIAGRAMS ER DIAGRAMS UML DIAGRAMS 5.4.1 5.4.2 5.4.3 5.4.4 5.4.5 5.4.6 5.5 USECASE DIAGRAM CLASS DIAGRAM SEQUENCE DIAGRAM COLLABORATION DIAGRAM ACTIVITY DIAGRAM DEPLOYMENT DIAGRAM

CONCLUSION

6. IMPLEMENTATION------------------------------------------------------------------50-74 6.1 INTRODUCTION IN JAVA 6.1.1 WORKING OF JAVA 6.1.2 METHOD OF IMPLEMENTATION 6.2 CONCLUSION 7. TESTING-------------------------------------------------------------------------------75-79
DEPT OF CSE, SMCET

GATEDWAY COMMUNITY & SERVICES

7.1

INTRODUCTION TO TESTING 7.2 7.3 LEVEL OF TESTING VALIDATION

8. 0UTPUT SCREENS-------------------------------------------------------------------80-92 9. CONCLUSION & FUTURE ENHANCEMENT---------------------------------93-94 10. BIBLIOGRAPHY----------------------------------------------------------------95-96 11. APPENDIX--------------------------------------------------------------------------- 97-101

LIST OF TABLES
DEPT OF CSE, SMCET

GATEDWAY COMMUNITY & SERVICES

5.1 5.1 5.3 5.4 5.5 5.6 5.7

LOGIN USER REGISTER CLIENT REGISTER ADMIN LOGIN SERVICES ADD SERVICES QUERIES

DEPT OF CSE, SMCET

GATEDWAY COMMUNITY & SERVICES

LIST OF DIAGRAMS 5.1 5.2 5.3 5.4 5.5 5.6 5.7 5.8 5.9 5.10 5.11 5.12 5.13 5.14 5.15 5.16 CONTEXT LEVEL ADMINISTRATOR MODULE CLIENT MODULE USER MODULE SEECOND LEVEL ADMINISTRATOR MODULE ERDIAGRAM USECASE FOR ADMINISTRATOR MODULE USECASE FOR USER MODULE USECASE FOR CLIENT MODULE USECASE FOR VISITOR MODULE USECASE FOR OVERALL SYSTEM CLASS DIAGRAM FOR OVERALL SYSTERM SEQUENCE DIAGRAM COLLABARATION DIAGRAM ACTIVITY DIAGRAM DEPLOYMENT DIAGRAM

DEPT OF CSE, SMCET

GATEDWAY COMMUNITY & SERVICES

INTRODUCTION

1.1 Motivation
DEPT OF CSE, SMCET

GATEDWAY COMMUNITY & SERVICES

These days every one have to approach directly to the shopping malls, stores, hospitals etc. and some of them may have no idea where that particular malls/hospital are located. Motivation may be rooted in the basic need to minimize physical pain and maximize pleasure. So our system is going to provide such services which will satisfy the needs of the customers. This application is useful for those who face the problems like wasting of time, facing risk etc.

1.2 Scope of the system


This system can be used by any gated way community which wants to maintain the database and utilize the various services provided by the application. In order to reduce the manual work and view the services which are provided by our website.

1.3 Objective of the project


The main aim of this project is to create a web application which maintains the Database and the information about various services which can be useful for various gated way communities. Vast information is maintained in this system so as to provide all the details of services.

Online service is purely an web application and lot of efforts is put to make it as user friendly.

Reduce the wastage and time of the users/visitors by going and enquiring manually. 8

DEPT OF CSE, SMCET

GATEDWAY COMMUNITY & SERVICES

1.4 Limitations of the project


Only the registered users/clients can access the website. Visitors can only view and send the feedback to the administrator. This application can be used only with in the single gated community.

1.5 Organization of the documentation on project


The project documentation is divided into seven units. The description about these units is as follows. Introduction unit predominantly deals with the introduction of the project. Literature Survey deals with the various existing systems and their disadvantages. Analysis deals with the various requirements of the project, Context diagrams and Flowcharts. Design showcases the UML diagrams according to the user requirements specified in the SRS. Implementation lays emphasis on the implementation of the project. It also explains the key services offered by the project. These services are depicted using the output screens. Testing and validation deal with the various test cases which are used to test the effective implementation of the project.

DEPT OF CSE, SMCET

GATEDWAY COMMUNITY & SERVICES

LITERATURE SURVEY

2.1 Present situation


DEPT OF CSE, SMCET

10

GATEDWAY COMMUNITY & SERVICES

Gated communities are neighborhoods enclosed by walls or fences, and providing services to members in that community. Gated communities exist throughout the United States. Gated communities are designed to providing services and maintaining the database about the homes and apartments are located. There are a number of reasons that individuals from all walks of life may choose to live within the enclosures of a gated community. Gated communities are not reserved for the upper class and the wealthy or for the most affluent of cities. Gated communities can be found in many towns in every state. In USA Today, it was estimated that nearly seven million families lived in gated communities, and four million of these families lived in a community where it was impossible to gain access without some sort of security clearance. Residents of gated communities may own their own home, or they may rent from someone else. Residents of gated communities represent all different racial groups. Present the gated-way community & services are providing the service only for drug edition. Gateway Community Services takes action against addiction through a wide range of programs and services. From prevention to out patient, detoxification to residential, family counseling to transitional care, our programs and services our services provide the comprehensive customized care each individual needs. Gateway treats many forms of addiction, including alcohol, prescription drugs, crack, methamphetamine, ecstasy, cocaine and marijuana. Fees are determined using a sliding scale with no individual being refused services for inability to pay. Medical and some insurance companies cover the cost of treatment.

DEPT OF CSE, SMCET

11

GATEDWAY COMMUNITY & SERVICES

2.2 What we are going to do


In the above paragraph what we have noticed is in every gated community only one service is being provided to the users which is not sufficient to the users. So in our site we have many services such as restaurants, hospitals, Coffee clubs, shopping malls, Online shopping etc. Here you can find more services as required by the users when ever the want. This site not only shows you the services but also links you directly to the required service as per your need. So that you can directly contact to the clients and use the services. But in order to use the services provided by our gated-community all the users must be registered ones. Not only users but also the visitors can enter into our site and can only view all the services. And if the visitor is interested to use any of the service then he is also permited to register into our site.

2.3 What we have done


We have create a web application which is useful for providing many more services such as hospitals, restaurants, etc. This application is mainly developed keeping in mind that the services mentioned in our site are only for registered ones. This application is going to serve for single community.

DEPT OF CSE, SMCET

12

GATEDWAY COMMUNITY & SERVICES

SYSTEM ANALYSIS

3.1 Introduction
DEPT OF CSE, SMCET

13

GATEDWAY COMMUNITY & SERVICES

Gated communities are neighborhoods enclosed by walls or fences, and providing services to members in that community. In those services we can provide online food services, marketing, travel agency etc. Some gated communities may even have their own places of worship. Gated communities exist throughout the United States. Gated communities are designed to providing services and maintaining the database about the homes and apartments are located. There are a number of reasons that individuals from all walks of life may choose to live within the enclosures of a gated community. Gated communities are not reserved for the upper class and the wealthy or for the most affluent of cities. n USA Today, it was estimated that nearly seven million families lived in gated communities, and four million of these families lived in a community where it was impossible to gain access without some sort of security clearance. Residents of gated communities may own their own home, or they may rent from someone else. Residents of gated communities represent all different racial groups.

3.2 Existing System


The existing system is quite difficult where the person needs to go to particular place to get the required service. The required service may or may not be available i.e., it may be closed on that day. So in order to get the required services as per their requirements what they have to do is just visit our site and can have the detailed information about the service.

Every person needs to go to the particular location for reporting the problem. The person who is responsible for taking complaints may or may not be there.

3.3 Proposed System


DEPT OF CSE, SMCET

14

GATEDWAY COMMUNITY & SERVICES

Gated-way community & Services is internet based application. Through this system we can provide various kinds of services like Hospital, Restaurant, Shopping malls etc In the web site it is very simple to get such kind of facilities. In this system the members can post the query to the administrator. Later the administrator will respond to those queries. The query status will be displayed all the time in the application and in this daily, weekly, monthly problem reports are generated. GCS is the one which provides direct communication with the members/users where he gets an immediate response for the queries and requests they are facing.

3.4 User Requirements


1. Welcome screen 2. Registration screen 3. Login screen 4. Admin Home Page 5. Client Registration screen 6. Client Home Page 7. Admin updating screen

3.5 Software Requirements


Operating System : Window T or XP/Linux Server: Apache Tomcat 5.5 or above Platform : Java Database: SQL Server 2000 Web Technologies: JSP and Servlets

3.6 Hardware Requirements


DEPT OF CSE, SMCET

15

GATEDWAY COMMUNITY & SERVICES

Server configuration Minimum 20GB Hard Disk Processor: Pentium IV RAM: 512MB 52-bit CD Rom Drive 101 Key Board Standards

Windows or Linux with apache and SQL Server pre-loaded

Client configuration
Minimum 2 GB Hard disk A terminal with an internet explorer any other browser. Network connection

3.7 Features of the project


Every visitor of the site can register themselves easily. All the information of users, clients and their services are stored in the centralized location. Generating different reports of problems is also possible. There will be one person called administrator who is always responsible to respond the queries. All the queries will reach the administrator and the solution for the queries will be responded to the persons who posed the query. No extra charges are posed on members using this system.

DEPT OF CSE, SMCET

16

GATEDWAY COMMUNITY & SERVICES

3.8 Conclusion
As mentioned above, the existing system is facing the problems as the person needs approach the location to report his problem/complaint. So the GCS system can overcome this problem so that the users can post their queries and get them solved with in a quick time

DEPT OF CSE, SMCET

17

GATEDWAY COMMUNITY & SERVICES

SYSTEM SPECIFICATION

DEPT OF CSE, SMCET

18

GATEDWAY COMMUNITY & SERVICES

4.1 Introduction
In this phase, the instructional problem is clarified, the instructional goals and objectives are established. The GCS system has modules as listed below: Administrator Client Database update of Clients and Users.

4.2 Functional Requirements


This section analyzes various angles of the functionality to be developed. We need to use each type of analysis for the entire system. Select only that analysis that best allow us to complete the understanding of the requirements. Web describes the functional requirements by giving various use cases.

Administrator
The entire system is under Admin and all the operations like View, Update, Request and responding to the queries given by the users. And the main responsibility of the administrator is to maintain database of all the details of clients and users.

1. Manage events: Under this Admin manages the below modules: A. Login B. View C. Update D. Response
DEPT OF CSE, SMCET

19

GATEDWAY COMMUNITY & SERVICES

E. Request View: Administrator is the only one who is going to view the details of Clients, Users and the services. Update: Administrator can add the newly registered users, Clients details and store those details in the database. Response: This module is used to respond for the Queries if needed by admin.

Client
Client is a member in the website who is externally going to provide various services to the gated-way communities. Only the registered clients can post their services in the website. A. Login B. Request C. Provide services D. Queries

User
Here users are the one who are registered to our website. Only registered users can view all the services provided. And the services they like are connected to their respective sites so that user can directly interact with clients regarding the services. A. Register B. Login C. Feedback

DEPT OF CSE, SMCET

20

GATEDWAY COMMUNITY & SERVICES

4.2.1 Feature Analysis


This specifies which outputs should be produced from given inputs. They describe the relationship between the inputs and outputs of the system for each function requirement a detailed description al all data inputs and their sources and the range of valid inputs must be specified. All the operations to be performed on the input to obtain data should be specified.

4.2.2 Functional Hierarchy


Functional hierarchy analyzes various angles of functionality to be developed. We need to use each type of analysis for entire system. Select only that analysis that best allow us to complete the understanding of requirements.

4.3 Non-Functional Requirements


Describe user visible aspects of the system that are not directly related with the functional behavior of system. Non functional requirements include quantitative constraints, such as response time (i.e., how fast the system reacts to user commands) or accuracy (i.e., how precise the system numerical answers).

4.3.1 Performance Requirements


System can withstand eve though any number of users requested the desired service. As GSC is a internet application and it provide direct communication with the user of the system where they can get their queries or problems resolved and they can get update information of services.

DEPT OF CSE, SMCET

21

GATEDWAY COMMUNITY & SERVICES

4.3.2 Safety and Reliability


By incorporating a robust and prove DBMS (SQL Server 2000) into the system, reliable performance and integrity of data is ensured. There must be a power backup for server system.

4.3.3 Security Requirements


This is the main concept in case of GCS. The application contains the secrecy of users password and the details of users. This is maintained by using user ids and passwords. Only the registered users of the college can access the system.

4.3.4 Software Quality Attributes


The GCS maintains good quality. Quality in the sense provides good services to the users of the system. The services provided are to update the database and retrieve those services from the database by the users and visitors.

4.4 Conclusion
We conclude that these are minimum requirements that are needed to be provided for the successful completion of this application.

DEPT OF CSE, SMCET

22

GATEDWAY COMMUNITY & SERVICES

PROJECT DESIGN

DEPT OF CSE, SMCET

23

GATEDWAY COMMUNITY & SERVICES

5.1 Introduction
This project is aimed at developing an GCS system for the various facilities provided in the campus and problems regarding the facilities. This system is used to develop a website to an organization. As this project is dealing with a college as organization. A model is simplification of reality. It provides the blue prints of a system. The unified Modeling Language is a graphical language for visualization, specifying, constructing and documenting the artifacts of a software intensive system. The UML gives a standard way to write a systems blue prints, covering conceptual things, such as classes written in a specific programming language, database schemas and reusable software components.

5.2 Data Flow Diagrams


A data-flow diagram (DFD) is a graphical representation of the flow of data through an information system. DFDS can also be used for visualization of data processing (structured design). On a DFDs, data items flow from an external data source or an internal data store to an internal data store or an external data sink, via an internal process.

DEPT OF CSE, SMCET

24

GATEDWAY COMMUNITY & SERVICES

There are different levels that exist in DFDs they are: Context Diagram Level 0 diagram Level 1 diagram Level 2 diagram

In this project we have only 3 phases: Context Level Diagram Level 0 diagram Level 1 diagram

Context-Level Diagram

Client

Admin

Gated-Way Community and services

User

Visitor

DEPT OF CSE, SMCET

25

GATEDWAY COMMUNITY & SERVICES

Level-0 Diagram

Fig No 5.2 First level diagram for Administrator module

DEPT OF CSE, SMCET

Fig No 5.3 First level diagram for Client module 26

GATEDWAY COMMUNITY & SERVICES

Fig No 5.4 First level diagram for User module

Level-1 Diagram

Fig No 5.5 Second level diagram for Administrator module

DEPT OF CSE, SMCET

27

GATEDWAY COMMUNITY & SERVICES

5.3 ER Diagram
An entity-relationship (ER) diagram is a specialized graphic that illustrates the interrelationships between entities in a database. ER diagrams often use symbols to represent three different types of information. Boxes are commonly used to represent entities. Diamonds are normally used to represent relationships and ovals are used to represent attributes.

Fig No 5.6 ER diagram for system

DEPT OF CSE, SMCET

28

GATEDWAY COMMUNITY & SERVICES

Table No 5.1 Login Attribute Id Password Type Data type Varchar Varchar Varchar

Table No 5.2 Structure of User registration Attribute Userid Password Confirmpwd Gender DOB Community Country Address Data type Varchar Varchar Varchar Varchar Varchar Varchar Varchar Varchar

Table No 5.3 Structure of Client registration Attribute Clientid Password Confirmpwd Gender Services Country Address Data type Varchar Varchar Varchar Varchar Varchar Varchar Varchar

DEPT OF CSE, SMCET

29

GATEDWAY COMMUNITY & SERVICES

Table No 5.4 Structure of Adminlogin Attribute Userid Table No 5.5 Structure of Services Attribute Services Data type Varchar Data type Password Varchar

Table No 5.6 Structure of Addservices Attribute Servcies Table No 5.7 Structure of Queries Attribute Query Data type Varchar Data type Varchar

5.4 UML Diagrams


The basic building blocks in UML are things and relationships; these are combined in different ways following different rules to create different types of diagrams. In UML there are nine types of diagrams, below is a list and brief description of them. 1 Use case diagrams: shows a set of use cases, and how actors can use them. 2 Class diagrams: describes the structure of the system, divided in classes with different connections and relationships. 3 Sequence diagrams: shows the interaction between set of objects, through the messages that may be dispatched between them.
DEPT OF CSE, SMCET

30

GATEDWAY COMMUNITY & SERVICES

4 State Chart diagrams: state machines, consisting of states, transitions, events and activities. 5 Activity diagrams: shows the flow through a program from an defined start point to an end point. 6 Object diagrams: a set of objects and their relationships, this is a snapshot of instances of the Things found in the class diagrams. 7 Collaboration diagrams: collaboration diagram emphasize structural ordering of objects that send and receive messages. 8 Component diagrams: collaboration diagram emphasize structural ordering of objects that send and receive messages. 9 Deployment diagrams: shows the configuration of run-time processing nodes and components that live on them.

UML Diagrams classification


A software system can be said to have two distinct characteristics: a structural, static part and a behavioral, dynamic: part. In addition to these two characteristics, an additional characteristic that a software system possesses in related to implementation. Before we categorize UML diagrams into each of these three characteristics, let us take a quick look at exactly what these characteristics are: Static: The static characteristic of a system is essentially the structural aspect of the system.

DEPT OF CSE, SMCET

31

GATEDWAY COMMUNITY & SERVICES

Dynamic: The behavioral features of a system; for example, the ways a system behaves in response to certain events or actions are the dynamic characteristics of a system.

Implementation: The implementation characteristic of a system is an entirely new feature that describes the different elements required for deploying a system. The UML diagrams that fall under each of these categories are: Static Use case diagrams Class diagram

Dynamic Object diagram State diagram Activity diagram Sequence diagram Collaboration diagram

Implementation Component diagram Deployment diagram

UML Diagrams for GCS

DEPT OF CSE, SMCET

32

GATEDWAY COMMUNITY & SERVICES

In the field of software engineering, the Unified Modeling Language (UML) is a standardized visual specification language for object modeling. UML is a general purpose modeling language that includes a graphical notation used to create an abstract model of a system, referred to as a model.

5.4.1 Use-Case Diagram


A use case diagram is a diagram that shows a set of use cases, actors and their relationships and the courses of actions that can be performed. It is used to illustrate the static use case view of a system. Administrator Module

Fig No 5.7 Administrator Module

DEPT OF CSE, SMCET

33

GATEDWAY COMMUNITY & SERVICES

User Module

Fig No 5.8 User Module Client Module

DEPT OF CSE, SMCET

34

GATEDWAY COMMUNITY & SERVICES

Fig No 5.9 Client Module Visitor Module

search

visitor feed back

system

Fig No 5.10 Visitor Module

DEPT OF CSE, SMCET

35

GATEDWAY COMMUNITY & SERVICES

Overall System

Fig No 5.11 Overall System Module

DEPT OF CSE, SMCET

36

GATEDWAY COMMUNITY & SERVICES

Use case specification


User Case Name: Update

1 Brief Description This use case describes how the users performs the operations 2 Actors 2.1 Administrator 2.2 User 2.3 Client 2.4 Visitor These actors perform update operation in the following basic flow. 3 Preconditions There is an active network connection to the database as soon as they are login with validated user id and password. 4 Basic Flows of Events 1. The use case begins when Administrator logins to the system by entering login id and password. 2. After login Administrator Updates services,user/client details and notifications 3. The use case ends successfully. 5 Alternative Flows 5.1 Invalid User If in step 2 of the basic flow Administrator the use case: Validate User does not complete successfully, then the use case ends with a failure condition.

DEPT OF CSE, SMCET

37

GATEDWAY COMMUNITY & SERVICES

6.Key Scenarios
6.1 No Response from database. 7 Post-conditions 7.1 Successful Completion The user has received their ids and the internal logs have been updated. 7.2 Failure Condition The logs have been updated accordingly. User Case Name: Verifies

1 Brief Description This use case describes how the administrator verifies the operations 2 Actors that perform verification 2.1 Administrator 3 Preconditions There is an active network connection to the database as soon as they are login with validated user id and password. 4 Basic Flows of Events 1. The use case begins when Administrator logins to the system by entering login id and password. 2. Administrator performs verification on accounts that are generated on the account reports of clerk. 3. The use case ends successfully.

DEPT OF CSE, SMCET

38

GATEDWAY COMMUNITY & SERVICES

5 Alternative Flows 5.1 Invalid User If in step 2 of the basic flow Administrator the use case: Validate User does not complete successfully, then 1. The use case ends with a failure condition 6 Key Scenarios 6.1 No Response from database. 7 Post-conditions 7.1 Successful Completion The user has received their ids and the internal logs have been updated. 7.2 Failure Condition The logs have been updated accordingly. User Case Name: maintaining

1 Brief Description This use case describes how the clerk generate reports 2 Actors 2.1 User 3 Preconditions There is an active network connection to the database as soon as they are login with validated user id and password.

DEPT OF CSE, SMCET

39

GATEDWAY COMMUNITY & SERVICES

4 Basic Flows of Events 1. This use case tells that the reports generation. 2. After clerk entering data in to the database if he/she wants to retrieve the data he generate reports so that viewing becomes easy and transfer of reports may also be easy. 3. After generating reports Quit from the action performed. 5 Alternative Flows 5.1 Invalid User If in step 2 of the basic flow Administrator the use case: Validate User does not complete successfully, then 1. The use case ends with a failure condition 6 Key Scenarios 6.1 No Response from database. 7 Post-conditions 7.1 Successful Completion The user has received their ids and the internal logs have been updated. 7.2 Failure Condition The logs have been updated accordingly. User Case Name: View

1 Brief Description This use case describes view action of student.

2 Actors 2.1 Client


DEPT OF CSE, SMCET

40

GATEDWAY COMMUNITY & SERVICES

3 Preconditions There is an active network connection to the database as soon as they are login with validated user id and password. 4 Basic Flows of Events 1. This use case is the one that describes the view action performed by an student in to a college website without any login facility. 5 Alternative Flows 5.1 Invalid User If in step 2 of the basic flow Administrator the use case: Validate User does not complete successfully, then 1. The use case ends with a failure condition 6 Key Scenarios 6.1 No Response from database. 7 Post-conditions 7.1 Successful Completion The user has received their ids and the internal logs have been updated. 7.2 Failure Condition The logs have been updated accordingly.

5.4.2 Class Diagram


A class diagram is a type of static structure that shows a set of classes, interfaces, collaborations, and their relationships. Graphically, a class diagram is a collection of vertices and arcs.
DEPT OF CSE, SMCET

41

GATEDWAY COMMUNITY & SERVICES

Class diagrams commonly contain the following things: Classes Interfaces Collaborations Dependency, generalization, and association relationships.

client1 Registor id pwd cpwd registeration() user1 login id; pwd; search() view() feedback() login id pwd service() request() queries() view() Query type add Query() checking()

Service add Service() delete service()

administrator1 Id pwd update() view() responce()

subadmin1 login id pwd update()

Fig No 5.12 Class diagram for GCS module Class diagram specification: Administrator Client o User
DEPT OF CSE, SMCET

42

GATEDWAY COMMUNITY & SERVICES

Responsibilities: Responsibilities that are to be performed by each object are Responsibilities for Administrator are Administrator is responsible for updating details like services details, user details, and notifications. Administrator is used to verify user account and clients account Administrator is responsible for giving user id and password for every registered user, clients and System administrator Responsibilities for user are User is responsible for viewing services and accessing it.

Responsibilities for client are

5.4.3 Sequence Diagram


Sequence diagrams display interaction between instances of classes and actors against a timeline. These diagrams are useful where the timing relationships between interactions are important. A sequence diagram is an interaction diagram that emphasizes the time ordering of messages. Graphically, a sequence diagram is a table that shows objects arranged along the Xaxis and messages, ordered in increasing time, along the Y-axis. An object lifeline is the vertical dashed line that represents the existence of an object over a period of time. The focus of control is tall, thin rectangle that shows the period of time during which an object is performing an action either directly, or through the sub ordinate procedure.

DEPT OF CSE, SMCET

43

GATEDWAY COMMUNITY & SERVICES

Fig No 5.13 Sequence diagram

DEPT OF CSE, SMCET

44

GATEDWAY COMMUNITY & SERVICES

5.4.4 Collaboration Diagram


A collaboration diagram, also called a communication diagram or interaction diagram, is an illustration of the relationships and interactions among software objects in the Unified Modeling Language (UML). The concept is more than a decade old although it has been refined as modeling paradigms have evolved. A collaboration diagram resembles a flowchart that portrays the roles, functionality and behavior of individual objects as well as the overall operation of the system in real time. Objects are shown as rectangles with naming labels inside. These labels are preceded by colons and may be underlined. The relationships between the objects are shown as lines connecting the rectangles. The messages between objects are shown as arrows connecting the relevant rectangles along with labels that define the message sequencing.

Fig No 5.14 Collaboration diagram


DEPT OF CSE, SMCET

45

GATEDWAY COMMUNITY & SERVICES

5.4.5 Activity Diagram


Activity diagrams provide a way to model the workflow of a business process or a way to model class operation. These diagrams are very similar to a flow chart because we can model a workflow from activity to activity or activity to state. An activity diagram is typically used for modeling the sequence of activities in a process where as a state chart is better suited to model the discrete stage of an objects lifetime. The activity diagram is defined as the graphical demonstration of the workflow of the sequence of activities with iteration and concurrency. According to the definition of unified modeling language the activity diagrams are used to characterize the operational and business workflows of the activities in a system. It indicates the complete flow of work. From the definition of activity diagram it is known that the transition occurs which defines the state of the activity that follows one another. Thus the transition which describes the complete phase and state of the activities then it is said to be complete transition. It varies from a transition in the manner that it does not need a clear event; it is triggered by the complete achievement of the activity which is represented by the activity state. An activity state can be referred by some of the activity diagram and it indicates the interior arrangement of the activity state. In terms of simple definition the activity diagrams can be nested. The contents of the activity diagram can be arranged into the partitions using the solid vertical lines. The UML activity diagrams are used to describe the definition of the software engineering to define the workflow methods. The definition of activity modeling includes series of the actions.

DEPT OF CSE, SMCET

46

GATEDWAY COMMUNITY & SERVICES

Fig No 5.15 Activity diagram

DEPT OF CSE, SMCET

47

GATEDWAY COMMUNITY & SERVICES

5.4.6 Deployment Diagram


A deployment diagram depicts a static view of the run-time configuration of processing nodes and the components that run on those nodes. In other words, deployment diagrams show the hardware for your system, the software that is installed on that hardware, and the middleware used to connect the disparate machines to one another. You want to create a deployment diagram for applications that are deployed to several machines, for example a point-of-sales application running on a thin-client network computer which interacts with several internal servers behind your corporate firewall or a customer service system deployed using web services architecture such as Microsofts .NET. Deployment diagrams can also be created to explore the architecture of embedded systems, showing how the hardware and software components work together. In short, you may want to consider creating a deployment diagram for all but the most trivial of systems.

Fig No 5.16 Deployment diagram

DEPT OF CSE, SMCET

48

GATEDWAY COMMUNITY & SERVICES

5.5 Conclusion
UML gives a standard way to built systems blue prints covering conceptual things such as business process and system functions as well as concrete things such as classes written in specific programming language, database schemas and reusable software components. Thus the UML models we developed help us to visualize, specify the structure, template that guides in constructing a system even the documentations we have made.

DEPT OF CSE, SMCET

49

GATEDWAY COMMUNITY & SERVICES

IMPLEMENTATION

DEPT OF CSE, SMCET

50

GATEDWAY COMMUNITY & SERVICES

6.1 Introduction to Java


Java was conceived by James Gosling, Patrick Naughton, ChrisWarth, Ed Frank and Mike Sheridan at SUN Micro Systems Incorporation in 1991. It took 18 months to develop the first working version. This language was initially called OAK, but was renamed JAVA in 1995. Before the initial implementation of OAK in 1992 and the public announcement of Java in 1995, many more contributed to the design and evolution of the language.

OVERVIEW OF JAVA: An Object Oriented Programming Language(OOPL) developed at Sun Microsystems. A Virtual Machine Run Time Environment that can be embedded in web browser (IE, NN). Java is a powerful but lean object oriented programming language. It has generated a lot of excitement because it makes it possible to program for Internet by creating applets, programs that can be embedded in web page.

The context of an applet is limited only by ones imagination. For example, an applet can be an animation with sound, an interactive game or a ticker tape with constantly updated stock prices. Applets can be serious application like word processor or spreadsheet.

But Java is more than a programming language for writing applets. It is being used more and more for writing standalone applications as well. It is becoming so popular that many people believe it will become standard language for both general purpose and Internet programming. There are many buzzwords associated with Java, but because of its spectacular growth in popularity, a new buzzword has appeared ubiquitous. Indeed, all indications are that it will soon be everywhere. Java builds on the strength of C++. It has taken the best features of C++ and discarded the more problematic and error prone parts. To this lean core, it has added garbage collection (automatic memory management), multithreading (the capacity for one

DEPT OF CSE, SMCET

51

GATEDWAY COMMUNITY & SERVICES

program to do more than one thing at a time), security capabilities. The result is simple, elegant, powerful and easy to use.

Java is actually a platform consisting of three components: Java Programming Language. Java Library of Classes and Interfaces. Java Virtual Machine.

It also has a Standardized set of Packages (Class, Interfaces): Creating Graphical User Interfaces Controlling Multimedia Data Communicating over Network

The following sections will say more about these components: FEATURES OF JAVA: PORTABILITY: One of the biggest advantages Java offers is that it is portable. An application written in Java will run on all the major platforms. Any computer with a Java based browser can run the applications or applets written in the Java Programming Language. A programmer no longer has to write one program to run on a Macintosh, another program to run on a windows machine, still another to run on a UNIX machine, and so on. In other words, with Java, developers write their programs only once. The virtual machine is what gives Java is cross platform capabilities.
DEPT OF CSE, SMCET

52

GATEDWAY COMMUNITY & SERVICES

Rather than being compiled into machine language, which is different for each operating systems and computer architecture, Java code is compiled into byte codes. With other languages, the program can understand. The problem is that other computers with different machine instruction set cannot understand that language. Java code, on the other hand is compiled into byte codes rather than a machine language. These byte codes go to the Java virtual machine, which executes them directly or translate them into the language that is understood by the machine running it. In Summary, these means that with the JDBC API extending Java, A programmer writing Java code can access all the major relational databases on any platform that supports the Java virtual machine.

OBJECT_ORIENTED: The Java programming language is object oriented, which makes program design focus on what you are dealing with rather than on how you are going to do something. This makes it more useful for programming in sophisticated projects because one can break the things down into understandable components. A big benefit is that these components can then be reused. Object oriented languages use the paradigm of classes. In simplest term, a class includes both the data and the functions to operate on the data. You can create an instance of a class, also called an object, which will have all the data members and functionality of its class. Because of this, you can think of a class as being like template, with each object being a specific instance of a particular type of class. The class paradigm allows one to encapsulate data so that specific data values are those using the data cannot see function implementation. Encapsulation makes it possible to make the changes in code without breaking other programs that use that code. If for example the implementation of a function is changed, the change is invisible to the programmer who invokes that function, and it does not affect his/her program, except hopefully to improve it. Java includes inheritance, or the ability to derive new classes from existing classes. The
DEPT OF CSE, SMCET

53

GATEDWAY COMMUNITY & SERVICES

derived class, also called a subclass, inherits all the data and the functions of the existing class, referred to as the parent class. A subclass can add new data members to those inherited from the parent class. As far as methods are concerned, the subclass can reuse the inherited methods as it is, changed them, and/or add its own new methods.

EASY In addition to being portable and object oriented, Java facilitates writing correct code. Programmers spend less time writing Java code and a lot less time debugging it. In fact, developers have reported slashing development time by as much as two thirds.

The following is a list of some of Javas features that make it easier to write correct code:

GARBAGE COLLECTION: Automatically takes care of allocating and reallocating memory, a huge potential source of errors. If an object is no longer being used (has no references to it), then it is automatically removed from memory. Dynamic binding is possible and often very useful, but static binding with strict type checking is used when possible.

SIMPLICITY: Makes Java easier to learn and use correctly. Java keep it simple by having just one way to do something instead of having several alternatives, as in some languages. Java also stays lean by not including multiple inheritance, which eliminates the errors and ambiguity that arise when you create a subclass that inherits from two or more classes. Java lets you add functionality to a class throws by the use of interfaces.

JAVA INCLUDES A LIBRARY OF CLASSES AND INTERFACES: The Java platform includes an extensive class library so that programmers can use already existing classes, as it is, create subclasses to modify existing classes, or implement interfaces to augment the capabilities of classes.
DEPT OF CSE, SMCET

54

GATEDWAY COMMUNITY & SERVICES

Both classes and interfaces contain data members (fields) and functions (methods), but there are major differences. In a class, fields may be either variable or constant, and methods are fully implemented. In an interface, fields must be constants, and methods are just prototypes with no implementations. The prototypes give the method signature (the return type, the function name, and the number of parameters with the type for each parameter), but the programmer must supply implementations. To use an interface, a programmer defines a class, declares that it implements the Interface, and then implements all the methods in that interface as part of the class. These methods are implemented in a way that is appropriate for the class in which the methods are being used. Interfaces let one add functionality to a class and give a great deal of flexibility in doing it. In other words interfaces provide most of the advantages of multiple inheritances without its disadvantages. A package is a collection of related Java classes and interfaces. The following list, though not complete, gives example of some Java packages and what they cover. Java.lang: The basic classes. This package is so basic that it automatically is included in any Java program. It includes classes dealing with numeric, strings, objects, runtime, security, and threads. Java.io: Classes that manages reading data from input streams and writing data to the output streams. Java.util: Miscellaneous utility classes, including generic data structures, bit sets, time, date, the string manipulation, random number generation, system properties, notification and enumeration of data structures. Java.net: Classes for network support.
DEPT OF CSE, SMCET

55

GATEDWAY COMMUNITY & SERVICES

Java.awt: Classes that manage user interface components such as windows, dialog boxes, buttons, and checkboxes, lists, menus, scrollbars, and text fields, the AWT stands for Abstract Window Toolkit. Java.awt.image: Classes for managing image data, including color models, dropping color flittering, setting pixel values, and grabbing snapshots. Java.applet: The Applet class, which provides the ability to write applets, this package also includes several interfaces that, connect an applet to its documents and to its document and to its document and to recourses for playing audio. Java.sql: The JDBC API, classes and interfaces that access databases and send SQL Statements.

The first three packages listed, java.lang, java.io and java.util form the foundation, they are basic classes and interfaces for general-purpose programming. Java development kit version1.1 added some new packages, with JDBC being one of them. Other new packages include such thing as Remote Method Invocation, Security and Java Beans, the new API for creating reusable components.

In Java, packages serve as the foundation for building other packages, as discussed in the following section.

EXTENSIBILITY:

A big plus for Java is the fact it can be extended. It was purposely written to be lean with the emphasis on doing what it does very well, instead of trying to do everything from the beginning; it was return so that extending it is very easy. Programmers can modify existing classes or write their own new classes or they can write a whole new package. The JDBC API,
DEPT OF CSE, SMCET

56

GATEDWAY COMMUNITY & SERVICES

the java.sql package, is one example of a foundation upon which extensions are being built. Other extensions are being added or worked on in area such as multimedia, Internet Commerce, conferencing, and telephony. In addition to extensions there are also main tools being developed to make existing capabilities easier to use. For example, there is already a tool that greatly Simplifies creating and laying out Graphical User Interfaces such as menus, Dialog boxes and buttons. SECURITY: It is important that a programmer not be able to write subversive code for Applications or applets. This is especially true with the Internet being used more and more extensively for services such as electronic commerce and electronic distribution of software and multimedia content.

The Java platform builds in security in four ways. The way memory is Allocated and laid out: In Java an objects location in memory is not determined until The runtime, as opposed to C and C++, where the compiler makes memory layout Decisions. As the result, a programmer cannot look at a class definition and figure out how it might be laid out in memory. Also since, Java has no pointers, a programmer cannot forge pointers to memory. The way incoming code is checked: The Java virtual machine doesnt trust any incoming code and subjects it to what is called byte code verification. The byte code Verifier, part of the virtual machine, checks that the format of incoming code is correct Incoming code doesnt forge pointers, it doesnt violate access restrictions, it accesses objects what they are.

DEPT OF CSE, SMCET

57

GATEDWAY COMMUNITY & SERVICES

The way classes are loaded: The Java byte code loader, another part of the virtual machine, whether classes loaded during program execution are local or from across a network. Imported classes cannot be substituted for built in classes, and built in classes cannot accidentally reference classes brought in over a network. The way access is restricted for untested code: The Java security manager allows user to restrict untested Java applets so that they cannot access the local network, files and other resources. JAVA PERFORMS WELL: Java performance is better than one might expect. Java has many advantages, such as having built in security and being interpreted as well as compiled, do have a cost attached to them. However, various optimizations have been built in, and the byte code Interpreter can run very fast the cost it doesnt have to do any checking. As a result, Java has done quite respectably in performance tests. Its performance numbers for interpreting byte codes are usually more than adequate to run interactive graphical end user applications.

For situations that require unusually high performance, byte codes can be translated on the fly, generating the final machine code for the particular CPU on which the application is running at run time. High level interpreted scripting language generally offer great portability and fast prototyping but poor performance. Low level compiled language like C and C++ offer great performance but require large amounts of time for writing and debugging code because of problems with areas such as memory management, pointers and multiple inheritances. Java offers good performance with the advantages of high level languages but without the disadvantages of C and C++. ROBUST:

The multi plat formed environment of the WEB places extraordinary demands on a program, because it must execute reliably in a variety of systems. Thus the ability to create robust programs was given a high priority in the design of Java. To gain reliability, Java restricts you in a few key areas to force you to find your mistakes early in program developments. At the same time, Java frees you from having to worry about many of the most common cause of
DEPT OF CSE, SMCET

58

GATEDWAY COMMUNITY & SERVICES

programming errors. Because Java is strictly typed language, it checks your code at compile time. However, it also checks your code at run time. In fact, many hard to track down bugs that often turn up in hard to reproduce runtime situations are simply impossible to create in Java. Knowing that what you have written will behave in a predictable way under diverse conditions is a key feature of Java to understand how Java robust.

Consider two main reasons for program failure: Memory management mistakes and mishandled exceptional conditions (run time errors). Memory management can be difficult, tedious task in traditional programming environments.

For example in C/C++ the programmer must manually allocate and free all dynamic memory. This sometimes leads to problems. For example some programmers some times forget the free memory that has been previously allocated. Or worse, they may free some memory that another part of their code is still using. Java virtually eliminates these problems by managing memory allocations and reallocations. Java helps in this area by providing object oriented exception handling. In a well-written Java a program should manage program all run time errors.

SCALABILITY Java platform is designed to scale well, from portable consumer electronic devices to powerful desktop and server machines. The virtual machine takes a small foot print and Java byte code is optimized to be small and compact. As a result, Java accommodates the need for low storage and for low bandwidth transmission over the Internet. In addition the Java operating system offers a standalone Java platform that eliminates host operating system overhead while still supporting the full Java platform. API makes Java ideal for low cost network computers whose sole purpose is to access the Internet.

MULTITHREADED:
DEPT OF CSE, SMCET

59

GATEDWAY COMMUNITY & SERVICES

Multithreading is simply the ability of a program to do more than one thing at a time. For example an application could be faxing a document at the same time it is printing another document. Or a program could process new inventory figures while it maintains a feed for current prices. Multithreading is particularly important in multimedia. A multimedia program might often be running a movie, running a audio track and displaying text all at the same time.

IMPORTANT TO THE INTERNET: The Internet helped catapult Java to the forefront of programming and Java in turn has a profound effect on the Internet. The reason is simple. Java expands the universe of objects that can move about freely in cyberspace. In a network, there are two broad categories of objects transmitted between the server, your personal computer, passive information and dynamic, active programs. For example, when you read your e-mail, you are viewing passive data. Even when you download a program, the programs code is still only passive data until you execute it. However, there is a second type of object that can be transmitted to your computer, a dynamic, self executing program. Such a program would be an active agent on the client computer, yet it would be initiated by the server. As desirable as dynamic, networked programs are, they also present serious problems in the areas of security and portability. Prior to Java cyberspace was effectively closed to half the entities that now live there. Java addresses these concerns and doing so, has opened the door to an exiting a new form of program. JAVA DATA BASE CONNECTIVITY: INTRODUCTION: Java Database Connectivity (JDBC) is a front-end tool for connecting to a server to ODBC in that respect, However JDBC can connect only Java clients and it uses ODBC for the connectivity. JDBC is essentially a low-level application programming interface. It is called a low-level API since any data manipulation, storage and retrieval has to be done by the program itself. Some tools which provide a higher-level abstraction or expected shortly. The next question that needs to be answered is why we need JDBC, once we have ODBC on hand. We can use the same ODBC to connect the entire database and ODBC is a proven technology. Problem for doing this is ODBC gives a C language API, which uses pointers extensively. Since Java does not have any pointers and is object-oriented sun Microsystems, inventor of Java developed to suit its needs.

DEPT OF CSE, SMCET

60

GATEDWAY COMMUNITY & SERVICES

REQUIREMENTS TO USE JDBC: To use JDBC you need a basic knowledge of database and SQL. Apart from this you need the jdk1.1 (Java Development Kit 1.1) or a version of Java since jdk1.1 and above come bundled with JDBC software.

After that you need to have a back-end database engine for which a JDBC driver is available. When JDBC drivers are not available JDBC-ODBC bridge drivers are used to access the database through ODBC. Back-end is not need when JDBC driver is capable of storing and retrieving the data itself, or if JDBC-ODBC bridge and the ODBC driver can be store and retrieve the information. DATABASE MODELS: JDBC and accessing the database through applets, and JDBC API via an intermediate server resulted in a new type of database model which is different from the client-servers through which the request should go it is named as single tier, two tier and multi tier architecture.

JDBC DRIVER TYPES: The JDBC drivers that we are aware of at this time fit into one of four categories:

JDBC-ODBC Bridge plus ODBC driver: The Java Soft bridge product provides

JDBC access via ODBC drivers. Note that ODBC binary code and in many cases database client code must be loaded on each client machine that uses this driver. As a result, this kind of driver is most appropriate on a corporate network where client installations are not a major problem, or for application server code written in Java in three-tier architecture.
Native-API partly-Java driver: This kind of driver converts JDBC calls into calls
DEPT OF CSE, SMCET

on the client API for Oracle, Sybase, Informix, DB2, or other DBMS. Note that, 61

GATEDWAY COMMUNITY & SERVICES

like the bridge driver, this style of driver requires that some binary code be loaded on each client machine.

JDBC-Net all-Java driver: This driver translates JDBC calls into a DBMS-

independent net protocol that is then translated to a DBMS protocol by server. This net server middle ware is able to connect its all-Java clients to many different databases. The specific protocol used depends on the vendor. In general, this is the most flexible JDBC alternative. It is likely that all vendors of this solution will provide products suitable for Internet use. In order for these products to also support Internet access, they must handle the additional requirements for security, access through firewalls, etc., that the Web imposes. Several vendors are adding JDBC drivers to their existing database middle ware products.

Native-protocol all-Java driver: This kind of driver converts JDBC calls into the

network protocol used by DBMS directly. This allows a direct call from the client machine to the DBMS server and is a practical solution for Internet access. Since many of these protocols are proprietary, the database vendors themselves will be the primary source. Several database vendors have these in progress.

Eventually, we expect the last two drivers will be preferred way to access database from JDBC. And the first two driver categories are interim solutions where direct all-Java drivers are not yet available. The last driver is in some sense the ideal one. However, there are many cases where JDBC-Net all-Java driver may be preferable. For example, where a thin DBMSindependent client is desired, or if a DBMS-independent protocol is standardized and implemented directly by many DBMS vendors.

DEPT OF CSE, SMCET

62

GATEDWAY COMMUNITY & SERVICES

HTML
INTRODUCTION: The Hyper Text Markup Language (HTML) is a simple markup language used to create hypertext documents that are portable from one platform to another. HTML documents are SGML documents with generic semantic that are appropriate for representing information from a wide range of applications. This specification defines HTML version 3.2. HTML 3.2 aims to capture recommended practice as of early 96 and as such to be used as a replacement for HTML 2.0(RF1866). A set of instructions embedded in a document is called Markup Language. These instructions describe what the document text means and how it should look like in a display. Hyper Text Markup Language (HTML) is the language used to encode World Wide Web documents. It is a document layout and hyperlink specification language that defines the syntax and placement of special embedded directions that are not displayed by a web browser, but tells it how to display the contents of the documents including text, images and other supported media. USE OF HTML: Web site is a collection of pages, publications, and documents that reside on web sever. While these page publications, and a document as a formatted in any single format. You should use HTML for home page and all primary pages and the site. This will enable the millions of web users it easily access and to take advantage of your website. HTML is considered first for formatting any new material you plan to publish on the web. HTML documents are platform independent, meaning that they dont confirm to any standard. If they are created properly you can move home to any server platform or you can access them with any complaint www browser.

DEPT OF CSE, SMCET

63

GATEDWAY COMMUNITY & SERVICES

BLOCK OF HTML:

HTML elements perform a defined task. HTML uses two types of elements Empty tags(open tags) Container tags These tags differ because of what they represent. Empty tags represent formatting constructs such as line breaks and Horizontal rules. Container tags define a section of text and specify the formatting the container dot all of the selected text. A container tag has both a beginning and an ending. HTML LAYOUT: An HTML document consists of text, which comprises the content of the document and tags which, defines the structure and appearance of the document. The structure of an HTML document is simple. <HTML> <HEAD> <TITLE> the title of the HTML document </TITLE> </HEAD> <BODY> This is where the actual HTML documents Text lies which is displayed in the browser </BODY> </HTML>

DEPT OF CSE, SMCET

64

GATEDWAY COMMUNITY & SERVICES

5.3.4.1 PROGRAM DESCRIPTION: The first line i.e., <HTML> tag, HTML tag is beginning tag and second line is starting tag for head section is <HEAD> The third line i.e., <TITLE> form example program </TITLE> is the title of the program. It defines a text string that is interpreted as the HTML title of the document. The tag </HEAD> will end the HEAD section of the program. Next tag is <BODY> the beginning of the body section where HTML document text lies, which is

displayed in the browser. Next tags </BODY> </HTML> are the ending tags for the body section and html program respectively. Each document has a head and body delimited by the <HEAD> and <BODY> tag. The head is where you give your HTML document a title and where you indicate other parameters the browser may use when displaying the document. The body is where you put the actual contents of the HTML documents. This include the text for displaying the text. Tag also references special and hot spots that link your document to other documents. modules: Administrator Module Administrator is the module which plays a major role in this project. The main work of this module is to store data of services which are requested by the cliets in the database and provide userid and password to the rest of the members. Client Module

DEPT OF CSE, SMCET

65

GATEDWAY COMMUNITY & SERVICES

Client is the one who is going to provide services to the users. And in order to post his services in our site he must first register. Client is a member in the website who is externally going to provide various services to the gated-way communities. Only the registered clients can post their services in the website. User Module Only registered users can view all the services provided. And the services they like are connected to their respective sites so that user can directly interact with clients regarding the services. Here users are the one who are registered to our website.

Modules implementation

MODULES
Administrator

INPUT
id password

OUTPUT
Admin screen Register users Update servcies

Client

Client id password

Client screen Services feedback Queries List of services

User

user id password ------

Visitor

Search for services

DEPT OF CSE, SMCET

66

GATEDWAY COMMUNITY & SERVICES

6.2 Conclusion
The main theme of this project is to provide services to the gated-way communities through online. Here, in this project the users who are interested in our services they have to first register to our web site by entering id and password by which they will be a member of our community and can access our site at any time. With id and password they can login and can access the services which are being provided by our website.

JAVA SERVER PAGES (JSP)


INTRODUCTION: Java Server Pages (JSP's) permit server side Java logic to reside within the requested document. Upon request of a JSP document the server activates the specified JSP. The JSP then becomes responsible for providing an HTML response. The server side logic within a JSP is written in Java. The Java code segments, referred to as scriptlets, are generally responsible for providing dynamic HTML content to the JSP's response HTML. The JSP itself is compiled by the server, and is executed as an object that extends the Java Servlets API. As such, the HTTP Servlet request and response objects are available by the script lets defined within the JSP. This document reviews client-server design considerations in respect to the use of JSPs. Implementation options, particularly the use of JSP language extensions and use of Enterprise Java Beans (EJB's) will also be discussed. Focus will be placed on the presentation layer and
DEPT OF CSE, SMCET

67

GATEDWAY COMMUNITY & SERVICES

how the JSP is used to provide a user interface and communicate business logic requests to the supporting system. If we consider a 3-tier architectural WEB application, the browser becomes the client side application. The user communicates requests to the WEB/app server via the browser. The presentation layer receives the client requests and prepares the response and server side business functionality is executed. In the context of this example, the JSP engine represents the presentation layer. It is responsible for processing requests and responses. Additional messages may be passed between this layer and that which handles business processes represented below as EJBs.

FIGURE1 THE TECHNOLOGY: JSP technology uses XML - like tags and scriptlets. They are used to encapsulate presentation logic within the JSP. They can also initiate messages to distributed or server-side applications. The logical separation of presentation and business logic lies in the implementation of the JSP.
DEPT OF CSE, SMCET

68

GATEDWAY COMMUNITY & SERVICES

Enterprise Java Beans provide a distinct relationship between the implementation of business logic and the remote interfaces provided to the EJB client. The use of an EJB typically follows the pattern: The client application identifies itself to the server. The client application uses the Java Naming Directory service to locate the desired EJB. The client application retrieves a handle to the EJB Home and subsequently Remote interfaces.

The remote interface contains methods that the client is permitted to use. They represent a summary of the business logic that is implemented by the bean. The implementation logic is defined within the primary bean class. All IPC, database and resource details are restricted to the bean class. In constructing a JSP document, the creation of the HTML base is a prudent step. It becomes the visual template that JSP scriptlets are merged into. The post execution HTML produced from the completed JSP should be that of the original HTML document. With the exception of comment, dynamically generated HTML sections and JSP content substitutions. The scripting logic, except for where desired, is completely non visual in regard to the response HTML text. The construction of the HTML layout conceivably begins with a Web developer. The creation of the JSP pages would be similar if not identical to the methods used to construct industry
DEPT OF CSE, SMCET

69

GATEDWAY COMMUNITY & SERVICES

HTML pages. The next step would be the addition of JSP specific logic to identify the sections of the HTML that might be generated dynamically. This conversion step from pure HTML to JSP is where server side logic is added to the page. A completed JSP logically embodies presentation layer services and business functionality. Physically they are blended within the JSP in an as needed swapping of HTML and JSP code. Continued maintenance of the application and changes in the business logic need not affect the presentation layout. Likewise, changes in the presentation layout need not affect the scriptlet logic, it will however require that the WEB developer, not necessarily a JAVA programmer, show care in the handling of this file which is no longer pure HTML should any HTML maintenance become necessary. THE ALTERNATIVE: A design consideration intended to reduce the complexity of maintaining the HTML aspect of a JSP is to minimize the use of scriptlets in constructing a JSP. Custom tags, introduced in JSP 1.1, can equally produce the functionality provided by JSP scriptlets. Custom tags are application defined language extensions to Java Server Pages. Custom tags can be used within a JSP in the following ways: To produce html output. To produce JSP output (JSP expressions, directives, ...). To create objects. To define objects that can be seen as scripting variables within the parent JSP.
DEPT OF CSE, SMCET

70

GATEDWAY COMMUNITY & SERVICES

To iterate over a body of JSP/HTML text in a finite manner. To determine if section of the calling JSP should be processed or skipped. The goal of using custom tags to minimize the presence of scriptlets is to produce a more HTML like JSP. The advantages of this goal are self-evident if we consider projects that expect frequent HTML modifications. Assuming the business logic, pre-presented by the JSP tags, is stable it can be identically merged into various forms of the HTML layout, without explicitly inserting duplicate sections of scriptlet logic (Java code). Tag handlers implement JSP custom tags. One or more tag handlers can be listed in the Tag Library Descriptor files. References to these files are included in the JSP that intends to use a given tag handler. The tag handler itself is implemented as a Java object that extends the JSP body. Upon execution it has access capabilities to the JSP's Http servlet objects, page attribute and session attribute objects. It can, conceivably, provide a full HTML response to the client in the way that servlets operate. A significant distinction from Java Server Pages is that tag handlers are not designed to be dynamically compiled by the server. In respect to EJB's, a tag handler accesses an EJB in the same manner as the above scriptlet. It can additionally make available any object it creates, available to other tag handlers and JSPs. This is accomplished by the use of storage methods that operate within the scope of the page and session. This includes the retention of EJB remote interface objects that can be created once and re-used by subsequent JSPs via scriptlets or tags.

DEPT OF CSE, SMCET

71

GATEDWAY COMMUNITY & SERVICES

The JSP engine and Java Server Pages logically produce presentation layer services. They also provide the interface to business services (i.e. EJBs). The physical separation of the logic associated with these middle tier components is evident in the above example. The same EJB logic in the previous example is represented here by the tag references. Figure 2 gives a graphical representation of the physical control flow without the use of custom tags. The client initiates execution with a JSP request. The request via URL is directed to the WEB server that is responsible for servicing such requests. The JSP request triggers the JSP engine to locate and execute the corresponding JSP as a servlet object. The execution of the business logic is represented by the use of Enterprise Java Beans.

Figure 2

Logically identical, figure 3 illustrates the use of tag handlers by the JSP. This is the hidden logic implied in HTML example 2.

DEPT OF CSE, SMCET

72

GATEDWAY COMMUNITY & SERVICES

Figure 3 The JSP engine, in both figures, treats the compiled JSP object as a servlet object. Figure 3s tag handler object extends the JSP page body. This relationship grants tag handler access to various Servlets attributes. These attributes therefore permit the tag handler to conceivably inspect parameters passed by the client. CONCLUSION: As with other tools of the trade, innovations and nuances to existing tools do not invalidate existing design methodologies. They do however provide new versatility and the expansion of possibilities with regard to application design. Custom tag extensions, in contrast to standard tags, provide the application builder the ability to define custom tags to satisfy some functionality not provided by the standard API. To benefit by using tag extensions to reduce the amount of Java functionality that the JSP API provides, might seem oxymoronic, and it is. With the exception of dynamically compiled JSPs, the functionality provided by the two given examples are identical, which suggests that the payoff for implementing this server side alternative is purely cosmetic, and it is.

DEPT OF CSE, SMCET

73

GATEDWAY COMMUNITY & SERVICES

While a server side application designer does not typically consider the cosmetic aspect of implementing source code, JSP source code might prove to be the exception. It does after all suggest the strong possibility that a Web/HTML developer perform the continued maintenance of the HTML portion of the JSP. This is a role, of course, traditionally allied with client side responsibilities. The nuances introduced by JSP custom tags present nuances in the maintenance of JSPs. The arguments presented here presume that the HTML produced by the JSPs in discussion are non-trivial HTML documents, although non-complex HTML documents may benefit from similar design considerations

DEPT OF CSE, SMCET

74

GATEDWAY COMMUNITY & SERVICES

TESTING

DEPT OF CSE, SMCET

75

GATEDWAY COMMUNITY & SERVICES

7.1 Introduction of Testing


Testing is a process of executing a program with the intent of finding an error. A good test case is one that has a high probability of finding an as-yet-undiscovered error. A successful test is one that uncovers an as-yet-undiscovered error. System testing is the stage of implementation, which is aimed at ensuring that the system works accurately and efficiently as expected before live operation commences. It verifies that the whole set of programs hang together. System testing requires a test consists of several key activities and steps for run program, string, system and is important in adopting a successful new system. This is the last chance to detect and correct errors before the system is installed for user acceptance testing. The software testing process commences once the program is created and the documentation and related data structures are designed. Software testing is essential for correcting errors. Software testing is the critical element of software quality assurance and represents the ultimate the review of specification design and coding. Testing is the process of executing the program with the intent of finding the error. A good test case design is one that as a probability of finding a yet undiscovered error. A successful test is one that uncovers a yet undiscovered error. Any engineering product can be tested in one of the two ways.

7.2 Levels of Testing


Testing

DEPT OF CSE, SMCET

76

GATEDWAY COMMUNITY & SERVICES

A process of executing a program with the explicit intention of finding errors, that is making the program fail. Software Testing It is the process of testing the functionality and correctness of software by running it. Process of executing a program with the intent of finding an error. A good test case is one that has a high probability of finding an as yet undiscovered error. A successful test is one that uncovers an as yet undiscovered error. Software Testing is usually performed for one of two reasons: Defect detection Reliability estimation

Black Box Testing


Applies to software systems or module, tests functionality in terms of inputs and outputs at interfaces. Test reveals if the software function is fully operational with reference to requirements specification.

White Box Testing


Knowing the internal workings i.e., to test if all internal operations are performed according to program structures and data structures. To test if all internal components have been adequately exercised.

Software Testing Strategies


A strategy for software testing will begin in the following order: 1. 2. 3. Unit testing Integration testing Validation testing
DEPT OF CSE, SMCET

77

GATEDWAY COMMUNITY & SERVICES

4.

System testing

Unit testing
It concentrates on each unit of the software as implemented in source code and is a white box oriented. Using the component level design description as a guide, important control paths are tested to uncover errors within the boundary of the module. In the unit testing, The step can be conducted in parallel for multiple components.

Integration testing
Here focus is on design and construction of the software architecture. Integration testing is a systematic technique for constructing the program structure while at the same time conducting tests to uncover errors associated with interfacing. The objective is to take unit tested components and build a program structure that has been dictated by design.

Validation testing
In this, requirements established as part of software requirements analysis are validated against the software that has been constructed i.e., validation succeeds when software functions in a manner that can reasonably expected by the customer.

System testing
DEPT OF CSE, SMCET

78

GATEDWAY COMMUNITY & SERVICES

In this software and other system elements are tested as a whole.

7.3 Validation
At the end of integration testing software is completely assembled as a package. Validation testing is the next stage, which can be defined as successful when the software functions in the manner reasonably expected by the customer.

Test cases
Test case Feature Input Expec ted output Login in to admin to get validat ed page. Observe d input Expected through given input and output. Description of test case This is a login provided by admin to himself for maintaining DB. Valid or invalid Valid when uid and pwd are correct. Invalid when wrong. Valid when uid and pwd are correct. Invalid when wrong. Valid when uid and pwd are correct. Valid Valid Remarks

Admin Login

This login is to perform some operations on login db.

Valid id and passwor d.

Valid

User login

All the services in the site are going to display.

Valid id and passwor d.

The respect ive user page has to display .

Expected through given input and output.

This is a login provided by admin to all the users.

Client login

It has to provide the services.

Valid id and passwor d.

The respect ive client page has to

Expected through given input and output. 79

This is a login provided by admin to all

DEPT OF CSE, SMCET

GATEDWAY COMMUNITY & SERVICES

display .

the clients.

Invalid when wrong.

OUTPUT SCREENS

DEPT OF CSE, SMCET

80

GATEDWAY COMMUNITY & SERVICES

DEPT OF CSE, SMCET

81

GATEDWAY COMMUNITY & SERVICES

Main screen

DEPT OF CSE, SMCET

82

GATEDWAY COMMUNITY & SERVICES

DEPT OF CSE, SMCET

83

GATEDWAY COMMUNITY & SERVICES

This is a Community website as we enter into the main page we see Home User/Client Logins Services About Us Contact Us FeedBack

Administrator login screen


DEPT OF CSE, SMCET

84

GATEDWAY COMMUNITY & SERVICES

DEPT OF CSE, SMCET

85

GATEDWAY COMMUNITY & SERVICES

Admin login page

As the administrator login the above application will be displayed: The operations of administrator are: View Update Response Request

DEPT OF CSE, SMCET

86

GATEDWAY COMMUNITY & SERVICES

User Registration Form

DEPT OF CSE, SMCET

87

GATEDWAY COMMUNITY & SERVICES

Client Registration Form

DEPT OF CSE, SMCET

88

GATEDWAY COMMUNITY & SERVICES

Login form of Client & User

DEPT OF CSE, SMCET

89

GATEDWAY COMMUNITY & SERVICES

Client login screen

DEPT OF CSE, SMCET

90

GATEDWAY COMMUNITY & SERVICES

User Login page

DEPT OF CSE, SMCET

91

GATEDWAY COMMUNITY & SERVICES

List of Services page

DEPT OF CSE, SMCET

92

GATEDWAY COMMUNITY & SERVICES

List of Hospitals

DEPT OF CSE, SMCET

93

GATEDWAY COMMUNITY & SERVICES

List of shopping malls

DEPT OF CSE, SMCET

94

GATEDWAY COMMUNITY & SERVICES

CONCLUSION AND FUTURE ENHANCEMENT

DEPT OF CSE, SMCET

95

GATEDWAY COMMUNITY & SERVICES

9.1 Conclusion
G.C.S. is the effective way of providing services to the gated-way communities and storing the data. Since it is an online organization i.e., here in the project gated-way communities can view and access the services at any time because it is based on internet services. Hence time consumption is less when compared to approaching the location. Each services or information given by the clients or feedbacks/details of the users are stored in the database which is used for further validations. As in this project we have mentioned three modules which play a crucial role in the application. Where administrator provides authentication to every user and client and all the information is being stored in the database at the administrator. If at all the security is not maintained the data stored may be lost so the data is maintained in a secured way so that though the system is affected through any crisis it can be safely stored and retrieved I future validations.

9.2 Future enhancement


The future scope of this project is that as this application is currently made useful only for single community so it can be extended to more than one communities further. As we have provided authentication only for single community but in further stages we can also provide the authentication to more number of communities at a time and can update the information for the notifications that are needed.

DEPT OF CSE, SMCET

96

GATEDWAY COMMUNITY & SERVICES

BIBLOGRAPHY

DEPT OF CSE, SMCET

97

GATEDWAY COMMUNITY & SERVICES

1. Big Java by Cay horstmann Tata McGrawhill 2nd Edition. 2. Introduction to web designing & Programing by Wang-Thomson Tata McGrawahill. Web sites reffered 1. www.hclcdc.com 2. www.google.com 3. www.wikipedia.com 4. www.gatedwayservices.com 5. www.gwcc.commnet.edu 6. www.gatewayrecovery.org

DEPT OF CSE, SMCET

98

GATEDWAY COMMUNITY & SERVICES

APPENDIX

DEPT OF CSE, SMCET

99

GATEDWAY COMMUNITY & SERVICES

Code for Login demonstration


<html> <%@ page import="java.sql.*;"%> <body> <% try{ out.println("hello"); String uid=request.getParameter("uid"); String pwd=request.getParameter("pwd"); out.println("hello1"); Class.forName("sun.jdbc.odbc.JdbcOdbcDriver"); Connection con=DriverManager.getConnection("jdbc:odbc:gc"); out.println("hello2"); Statement st=con.createStatement(); ResultSet rs=st.executeQuery("Select * from adminlogin where Userid='"+uid+"' and pwd='"+pwd+"' "); out.println("hello3"); if(rs.next()) { out.println("inside if"); String uid1=rs.getString(1); String pwd1=rs.getString(2); if(uid.equals(uid1) & pwd.equals(pwd1)) {

%>
DEPT OF CSE, SMCET

100

GATEDWAY COMMUNITY & SERVICES

<jsp:forward page="Adminlogin.html"/> <% } } else { %> <jsp:forward page="Error.html"/> <% } } catch(Exception e) { out.println(e); } %> </body> </html>

DEPT OF CSE, SMCET

101

GATEDWAY COMMUNITY & SERVICES

Code for User login


<%@page import="java.sql.*" %> <% try { String n=request.getParameter("uid"); String p=request.getParameter("upwd"); Class.forName("sun.jdbc.odbc.JdbcOdbcDriver"); Connection con=DriverManager.getConnection("jdbc:odbc:gc"); Statement st=con.createStatement(); ResultSet rs=st.executeQuery("select * from login where uid='"+n+"' and pwd='"+p+"' "); if(rs.next()) { String n1=rs.getString(1).trim(); String p1=rs.getString(2).trim(); if(n.equals(n1)& p.equals(p1)) { %> <jsp:forward page="Userlogin.html"/> <% } } else { %> <jsp:forward page="Error.html"/> <%
DEPT OF CSE, SMCET

102

GATEDWAY COMMUNITY & SERVICES

} } catch(Exception e) { out.println(e); } %> </body>

DEPT OF CSE, SMCET

103

Potrebbero piacerti anche