Oracle8i Java Stored Procedures Developer's Guide Release 2 (8.1.6) Part Number A81358-01 |
Library | Service | Contents | Index

## Java in the Database

To make Java files available to the JServer JVM, you must load them into the Oracle database as schema objects. As Figure 2-1 illustrates, `loadjava` can invoke the JVM's Java compiler, which compiles source files into standard class files.

The figure also shows that `loadjava` can set the values of options stored in a system database table. Among other things, these options affect the processing of Java source files. For example, the option `-encoding` localizes Java source files by specifying their character-encoding scheme. (For more information about the options table, see "Passing Options to the Compiler".)

#### Figure 2-1 Loading Java into the Oracle Database

Each Java class is stored as a schema object. The name of the object is derived from the fully qualified name (full name) of the class, which includes the names of containing packages. For example, the full name of class `Handle` is:

    oracle.aurora.rdbms.Handle

In the name of a Java schema object, slashes replace dots, so the full name of the class above becomes:

    oracle/aurora/rdbms/Handle

The Oracle RDBMS accepts Java names up to 4000 characters long. However, the names of Java schema objects cannot be longer than 30 characters, so if a name is longer than that, the system generates an alias (short name) for the schema object. Otherwise, the full name is used. You can specify the full name in any context that requires it. When needed, name mapping is handled by the RDBMS.

| Copyright © 1996-2000, Oracle Corporation. All Rights Reserved. |
Library | Service | Contents | Index