A lowdown on... Java
Posted on 21 Nov 2001 at 16:43
Java. Java. Java. Chances are any new release from a wide range of technologies - from mobile phones and PDAs to Web programming and enterprise servers - will make reference to this seemingly ubiquitous technology.
What is it that makes Java so important? Why is it more than just another programming language? And why, exactly, has Microsoft not fallen under its spell? Time for a lowdown...
Contents
- The makings of a baggy monster
In a nutshell (or bean, perhaps), Java lets you build systems that are platform-independent, capable of running across networks (including the Web) and - because it's a full-featured programming language - it can bring a new level of standardised functionality to small and previously dumb devices. It is possible, for example, for very small devices to access very large databases by means of well-tested function calls. It also supports fine-grained access and security profiles to police the behaviour of distributed programs. Essentially, it has offered the promise of programming the Web to good effect.
In slightly more detail, Java is a class-based, object-oriented language created by Sun Microsystems (slogan: 'the network is the computer'). It is heavily based on C++, which is the king of the jungle as far as programming languages are concerned, with its heavy-duty support for a variety of programming techniques and its wide professional usage. The developers of Java, however, sought to simplify things and to add a number of features for the networking world (and ultimately that meant the Internet).
In technical terms, the Java creators added features such as garbage collection (the automatic tidying up of unused variables) and support for explicit multithreading. They also removed some difficult C++ features, such as operator overloading (the ability to adapt the language to user-defined objects) and support for multiple inheritance (that a user defined object could be derived from multiple 'types' of ancestor rather than a more straightforward single inheritance).
More importantly, Java was designed from the start to execute across a network, securely. As well as the elimination of the use of pointers, which languages have traditionally used to access specific addresses in memory, the language was designed to be cross-platform even at an executable level (most languages are cross-platform in source-code form, in the sense that you have to recompile programs every time they are to run on different machines). The way Java approached this was to use intermediate byte-code rather than fixed, compiled binary. Essentially, programs are decoded on the fly by Java platform-specific Java interpreters.
These JVMs (Java virtual machines) are built for various platforms and provide a consistent, known environment for Java programs to run within. Java's slogan is 'write once, run everywhere' because, in theory, once a program is written in Java it can run on any JVM supported on any machine. The 'logic' of the program will remain unchanged because it can safely make assumptions about what will be provided when it tries to execute - the particularities of the machine that hosts the program will be taken care of by the particular runtime environment for that machine.
advertisement
- Motorola pays Lucas for its Droid
- Where are the killer apps for Windows?
- Will you hit the Orange iPhone "unlimited" cap?
- USB 3 first benchmark - it's here, and it's fast
- Why Windows 7 has forced me to worry about security
- How Dixons is (under)selling Windows 7
- Do I like Windows 7 because it's so like a Mac?
- No Windows 7 drivers turn Dell M1330 into a doorstop
- Is Windows 7 good looking enough to sway an Apple fan?
- Typekit brings print-like typography to the web
- The bulletproof Dell that costs an arm and a leg
- Microsoft Office 2010 Technical Preview: Q&A
- Lawnmowers, the TyTN II and one odd insurance request
- There'll never be a bulletproof OS
- How far can we trust apps?
- Five nice touches in Outlook 2010
- Building a better Google
- Beware HP's horrendous printer-driver glitch
- Microsoft debuts free Morro antivirus package
- Getting started with Search Server 2008 Express
advertisement

Printed from www.pcpro.co.uk

