The JavaTM Tutorial
Previous Page Lesson Contents Next Page Start of Tutorial > Start of Trail > Start of Lesson Search
Feedback Form

Trail: Overview

Networking and Connectivity

Various Java APIs let you safely interact with resources on the Internet, on the network, and in databases.

JDBC Database Access

Introduced in JDK 1.1, JDBC makes it possible to send SQL statements to a database and to process the results that are returned. JDBC provides uniform access to a wide range of relational databases and provides a common base on which database tools can be built.

The JDBC implementation includes a driver manager to support multiple drivers that mediate the connections between JDBC and various databases. A driver can be written either entirely in the Java programming language so it can be downloaded as part of an applet or in a mixture of the Java programming language and native methods if it needs to bridge to existing database access libraries.

In JDK 1.2 the java.sql package builds on the existing SQL functionality to include

Remote Method Invocation

Remote method invocation (RMI) first appeared in JDK 1.1 and lets Java applications use remote method calls (rather than sockets and streams) to communicate across a network. The communicating applications can be running on different computers on opposite sides of the planet. This higher-level, method-based approach to network communications allows access to a remote object as easily as to a local object.

JDK 1.2 RMI enhancements include remote object activation, downloadable socket factories, and other minor enhancements, including

Java IDL

Java IDL adds CORBA (Common Object Request Broker Architecture) capability to the Java platform to provide standards-based interoperability and connectivity. Java IDL is new with JDK 1.2, so distributed Web-enabled Java applications can transparently invoke operations on remote network services, using the industry-standard Object Management Group (OMG) interface definition language (IDL) and Internet Inter-ORB Protocol (IIOP) defined by the OMG. Runtime components include a fully compliant Java ORB for distributed computing using IIOP communication.

The two main Java IDL packages are org.omg.CORBA and org.omg.CosNaming. The org.omg.CORBA package supplies the mapping of OMG CORBA 1.0 to the Java programming language. An implementation of the ORB class is included so a programmer can use it as a fully functional object request broker (ORB). An ORB object handles, or brokers, method invocations between a client and the method implementation on the server. Because the client and the server can be anywhere on a network and the invocation and implementation can be in different languages, an ORB object does a lot of behind-the-scenes work to enable the communication.

The org.omg.CosNaming package specifies the naming service for Java IDL. The package and all of its classes and interfaces were generated by running the idltojava compiler on the file nameservice.idl, which is a module written in OMG IDL.

Security Architecture

JDK releases continue to enhance the security features inherent in the Java programming language and built into the Java platform. JDK 1.0.2 restricts applets to a secure environment, or sandbox, so they cannot access local system resources outside their sandbox. JDK 1.1 provides digitally signed Java ARchive (JAR) files to sign and to verify the signature on applet and application files.

JDK 1.2 introduces a strong security model and accompanying tools so end users and system administrators can extend the security policy to applications and can determine how much access to system resources an applet or a Java application can have. The JDK 1.2 security policy is easy to configure, provides fine-grain access control, and applies to all Java applets and applications. The JDK 1.2 security tools are JavaKey, for creating a database of keys; JAR Signer, for signing JAR files; and Policy Tool, for granting access to system resources.


Previous Page Lesson Contents Next Page Start of Tutorial > Start of Trail > Start of Lesson Search
Feedback Form

Copyright 1995-2005 Sun Microsystems, Inc. All rights reserved.