Dynamic Class Loading

SQL Anywhere and Adaptive Server allow you to specify Java classes.

  • Datatypes of SQL columns

  • Datatypes of Transact-SQL variables

  • Default values for SQL columns

jConnect version 6.05 and later implements DynamicClassLoader (DCL) to load a class directly from an SQL Anywhere or Adaptive Server server and use it as if it were present in the local CLASSPATH.

In jConnect 6.0 and earlier versions, only classes that appeared in the jConnect CLASSPATH were accessible, that is, any attempt of a jConnect application to access an instance of a class that was not in the local CLASSPATH, resulted in a java.lang.ClassNotFound exception.

All security features present in the superclass are inherited. The loader delegation model implemented in Java 2 is followed—first jConnect attempts to load a requested class from the CLASSPATH; if that fails, jConnect tries the DynamicClassLoader.

See Java in Adaptive Server for more detailed information about using Java and Adaptive Server.