26-02-2013, 04:05 PM
CHAT SERVER USING JAVA
CHAT SERVER USING JAVA.doc (Size: 127.5 KB / Downloads: 31)
DEFICIENCIES OF THE CONVENTIONAL
(MANUAL) SYSTEM
1. Lack of immediate retrieval of information
In manual system, lot of time is wasted in retrieving information. Much searching is required before required information is found. This wastes a lot of time of the user.]
2. Lack of immediate information storage
In manual system, it is difficult to store information at proper place at that very moment. This is because the person is unable to quickly locate the place were the information is to be stored.
3. Promote Updation not possible
Changes are quite natural in all work of life. Information and stored data also changes from time to time. This information up-to-date. However bringing about changes through the manual system is a slow and tedious process because of which inaccurate information storage occurs.
4. Very slow computation process
Lot of computational work is to be performing in the system. Activities are quite slow in the manual system and may also be incorrect.
5. Unplanned Working
The manual system lacks the element of planned working. Records related to customer are not properly maintained. This creates lot of problems at times like during information retrieval and storage.
6. Insignificant generation of managerial and strategic reports
In manual system, reports for management are difficult to be generated and strategic report almost impossible. These are because for these reports proper storage of information. It’s retrieval and it’s filtering are very important and very tough in manual system.
7. Accuracy
The manual system lacks accuracy in working and a number of operations may be performed incorrectly. The computations that are done in the organization may be incorrect and whatever reports are generated in the system may be inaccurate.
8. Reliability
The reliability of manual system is considered to be low because of the above given reasons including the fact that ‘To error in human’. Any task that is performed by man, always contain the risk of errors.
About Programming Language “Java”
Java was conceived by James gosling, Patric naughton, Chris warth, Ed frank, and Mike sheriden at Sun Microsystem, inc in 1991. This language was initially called “oak” but was renamed “Java” in 1995, between the initial implementation of oak in the fall of 1992 and public announcement of java in the spring of 1995, many more people contributed to the design and evolution of the language. Bill Joy, Arthur van hoff, jonathan payne, frank yellin, and tim lindholm were key contribution to the maturing of the original prototype.
Somewhere surprisingly, the original impetus for java was not the INTERNET ! Prototype. The primary motivation was to need for a platform-independent (that is architecture –natural) language that could be used to create software to be embedded in various consumer electronic devices such as microwave ovens and remote control as you can probably guess many different types of CPU are used as controllers the trouble with C and C++ (and most other language) is that they are designed to be compiled for a specific target. Although it is possible to compile a C++ program for just about any type of CPU, to do so requires a full compiler targeted for that CPU.
Java is a programming language and environment invented by James Gosling in 1994. Gosling was the first designer of the Java programming language and implemented its original compiler and virtual machine.
Java is the first and foremost programming Language. Creation of Java was driven by both elements in nearly equal measures which are:
1. To adapt to changing environments and uses.
2. To implement refinements and improvements in the art of programming.
"Java: A simple, object-oriented, distributed, interpreted, robust, secure, portable, high-performance, multithreaded, and dynamic language" –Java Soft
A Java Program: From Birth to Execution
1. Coding: Human-readable Java code is produced by the programmer
2. Building: A Java Development Tool "build’s the Java program into byte-code, which is saved as a ". class" file.
3. Loading: Via the web or command line, the class file is sent to the Java Virtual Machine (VM) with an attached digital signature. The Java VM is simply an interpreter.
4. Byte code Verification: The Java VM verifies the digital signature. When downloaded remotely, the Java VM isolates the Java program in a restricted part of memory. The Java program is not allowed to access local Hard drives and System resources.
5. Internal Integrity: Verification checks are made to insure that the loaded Java program is well formed. Data types are verified along with other syntax structure
6. Execution: Program execution begins
Java Project
In 1990, Sun Microsystems began a project called Green to develop software for consumer electronics. Gosling began writing software in C++ for embedding into such items as toasters, VCR's, and Personal Digital Assistants ( PDA's ). The embedded software makes more appliances more intelligent. Gosling's solution to the problem of C++ was a new language called Oak. Finally in 1995, Oak was renamed Java. Since then, Java is rising in popularity. Java Soft also sued Microsoft, for violating its Java license agreement. Microsoft wants to add Windows specific alterations to the Java language, which would blunt the "run anywhere" goal of Java.
Java Soft, which presents compatibility problems with existing web browsers and Virtual Machines are currently expanding Java. Its syntax is similar to C and C++, but it omits many of the features that make C and C++ complex, confusing, and unsafe. The Java platform was initially developed to address the problems of building software for networked consumer devices. It was designed to support multiple host architectures and to allow secure delivery of software components. To meet these requirements, compiled code had to survive transport across networks, operate on any client, and assure the client that it was safe to run.
The popularization of the World Wide Web made these attributes much more interesting. The Internet demonstrated how media-rich content could be made accessible in simple ways. Web browsers enabled millions of people to roam the Net and made Web surfing part of popular culture. At last there was a medium where what you saw and heard was essentially the same whether you were using a Mac, PC, or UNIX machine, and whether you were connected to a high-speed network or a slow modem.
Web enthusiasts soon discovered that the content supported by the Web's HTML document format was too limited. HTML extensions, such as forms, only highlighted those limitations, while making it clear that no browser could include all the features users wanted. Extensibility was the answer.
Sun's Hot Java browser showcases the interesting properties of the Java programming language and platform by making it possible to embed programs inside HTML pages.
These programs are transparently downloaded into the Hot Java browser along with the HTML pages in which they appear. Before being accepted by the browser, the programs are carefully checked to make sure they are safe. Like HTML pages, compiled programs are network- and host-independent. The programs behave the same way regardless of where they come from or what kind of machine they are being loaded into and run on.
Visitors to Web pages incorporating dynamic content can be assured that their machines cannot be damaged by that content. Programmers can write a program once, and it will run on any machine supplying a Java or Java 2 run time environment.
The Java language is very secure and platform independent when compared to alternative languages. Java's secret is the tightly integrated language model.
Java features
Simple
Java was designed to be easy for the professional programmer. It is easy to learn and can be used effectively. If you are an experienced C++ programmer, moving to Java will require very little effort.
Secure
There is a concept of applets in Java which can be downloaded without fear or virus or malicious content, because the Java programs are confined to Java execution environment and are not allowed to access other parts of the CPU.
Portable
The Java programs called Applets run in the JVM (Java virtual machine) environment that is in every browser therefore the programs can run anywhere.
Object Oriented
Java Classes follow the Oops concept of encapsulation, inheritance, and polymorphism.
Robust
Garbage collection and Exception handling make Java a robust language. In garbage collection the user doesn’t have to bother about the memory allocation as, when the object is no longer in use it is automatically deleted to release memory space.
Multithreaded
A single threaded application has one thread of execution running at all times and such programs can do only one task a time.
A multi-threaded application can have several threads of execution running independently and simultaneously. These threads may communicate and cooperate and will appear to be a single program to the user.
Interpreted
The Java code is compiled into the byte code, which is the class file. The byte code is then interpreted to the machine language by the JVM environment.
Distributed
Java handles the TCP/IP protocols, which makes it easier to use in Internet.
Some Other Features Of Java Programming
Encapsulation
ENCAPSULATION is the mechanisms that binds together code and the data it manipulates, and keeps both safe outside interference and misuse. It is a protective wrapper that prevents the code and data from being arbitrarily accessed by other code defined outside the wrapper.
Encapsulation is the capability to represent, denote and handle information at a higher level that is inherent to a computer or base language. Variables and methods are formerly known as instance variables and instance methods to distinguish from class variables and class methods.
Inheritance
Inheritance is the process by which one object acquires the properties of another object.
Classes inherit state and behavior from their superclass. A class is a blueprint or prototype that defines the variables and methods common to all objects of a certain kind.
Object oriented systems allow classes to be defined in terms of other classes. For example, mountain bikes, racing bikes and tandems are all subclasses of the bicycle class. Similarly, the bicycle class is the superclass of mountain bikes, racing bikes and tandems.
Each subclass inherits state (in the form of variable declarations ) from the superclass. Mountain bikes, racing bikes and tandems share some states : Cadence, speed, and the like. Also each subclass inherits methods from the superclass.