Wednesday, April 3, 2019
The Benefits of Java
The Benefits of burnt umber coffee tree INCLUDES A LIBRARY OF CLASSES AND INTERFACESThe chocolate syllabus accepts an extensive dissever library so that work outrs can use al demoy existing classes, as it is, create subclasses to substitute existing classes, or implement interfaces to augment the capabilities of classes.Both classes and interfaces contain information members ( palm) and functions (methods), but there are major differences. In a class, fields may be either variable or constant, and methods are in full implemented.To use an interface, a architectural planmer 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 centering that is appropriate for the class in which the methods are being used. Interfaces let one add functionality to a class and give a majuscule deal of flexibility in doing it.A piece of ground is a prayer of related Java clas ses and interfaces. The following list, however not complete, gives guinea pig of some(a) Java packages and what they cover.Java.lang The basic classes. This package is so basic that it automatically is include in any Java computer programme. It includes classes that intercepts with numeric, strings, objects, runtime, warrantor, and threads.Java.io Package that includes classes managing reading data in input streams and writing data into a directionput streams.Java.util Miscellaneous utility classes, including generic data structures, bit sets, time, date, the string manipulation, random number generation, system properties, telling and enumeration of data structures.Java.net Classes for mesh topology support.Java.awt Classes that manage drug user interface components such as windows, dialog boxes, buttons, checkboxes, lists, menus, scrollbars, and text fields, the AWT stands for Abstract Window Tool kit.Java.awt.image Classes for managing image data, including coloration models, dropping color flittering, setting pixel values, and grabbing snapshots.Java.applet The Applet class, which provides the top executive to write applets, this package in like manner includes several interfaces that connect an applet to its documents and to its document.Java.sql The JDBC API, classes and interfaces that irritate databases and send SQL Statements.The first common chord packages listed, java.lang, java.io and java.util form the basis, they are basic classes and interfaces for general-purpose schedule.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 mental synthesis other(a) packages, as discussed in the following section. chocolate IS EXTENSIBLEA big plus for Java is the fact it can be extended. It was by design written to be lean with th e emphasis on doing what it does very well, preferably of trying to do everything from the beginning, it was return so that extending it is very simple. The JDBC API, the java.sql package, is one model upon which extensions are being built.In addition to extensions there are to a fault 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 drug user Interfaces such as menus, Dialog boxes and buttons.SECURITYIt 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 delivery of software and multimedia content.The Java platform builds in gage in four ways.The way keeping is Allocated and laid out In Java an objects location in memory is not determined until The runtime, as opposed to C and C++, w here the compiler makes memory layout Decisions. As the result, a programmer cannot look at a class definition and figure out how it qualification be laid out in memory. Also since, Java has no pointers, a programmer cannot make pointers to memory.The way succeeding(prenominal) code is checked The Java virtual(prenominal) railcar doesnt trust any incoming code and subjects it to what is called throughte code verification. The throughte code Verifier, part of the virtual machine, checks that the format of incoming code is correctincoming code doesnt forge pointers, it doesnt violate access restrictions, it accesses objects what they are.The way classes are loaded The Java throughte 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 rest ricted 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 WELLJava 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 gain a cost attached to them. As a result, Java has make quite respectably in performance tests. Its performance numbers for agnize throughte codes are usually more than adequate to run interactive lifelike end user applications.For situations that require unusually high performance, throughte 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 crack great portability and fast prototyping but silly performance. Low level compiled language like C and C++ offer great performance but require large amount s of time for writing and debugging code be grow of problems with areas such as memory management, pointers and multiple inheritance. Java offers undecomposed performance with the advantages of high level languages but without the disadvantages of C and C++.JAVA IS ROBUSTThe multi platformed environment of the WEB places extraordinary demands on a program, because it mustinessiness scarper 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 rouge areas to force you to find your mistakes early in program developments. At the identical time, Java frees you from having to worry about many of the most common cause of 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 handle down bugs that often turn up in hard to create runtime situations are s imply impossible to create in Java. Knowing that what you piddle written will behave in a predictable way under diverse conditions is a key feature of Java to understand how Java robust.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.JAVA SCALES WELLJava platform is designed to scale well, from take-away consumer electronic devices to powerful desktop and server machines. 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 keep the full Java platform. API makes Java ideal for low cost network computers whose sole purpose is to access the Internet.JAVA IS MULTITHREADEDMultithreading is simply the ability of a program to do mo re than one thing at a time. For example an application could be faxing a document at the akin time it is printing another document. Or a program could suffice new inventory figures while it sustains a feed for current prices.JAVA IS IMPORTANT TO THE INTERNETThe 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 capacious categories of objects transmitted between the server, your personal computer, passive info 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 through the server. As desirable as dynamic, networked programs are, they also current stark 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.
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment
Note: Only a member of this blog may post a comment.