Skip navigation links

Oracle Database JDBC Java API Reference
11g Release 2

E13995-03


oracle.jdbc.driver
Class OracleLog

java.lang.Object
  extended by oracle.jdbc.driver.OracleLog


public class OracleLog
extends java.lang.Object

TRACE is a static variable that enables/ disables the invocation of the print calls during run-time. This static variable can be changed to 'static final' to allow the print calls to be compiled out completely.

Logging can also be controlled/filtered by using Java system properties. Note that system properties only work in Java applications but not in Applets. Note that the system propeties are examined once when the OracleLog class is loaded. These properties are listed in the following:

Since:
8.1.6

Field Summary
static java.util.logging.Level INTERNAL_ERROR
           
static boolean TRACE
           
static java.util.logging.Level TRACE_1
           
static java.util.logging.Level TRACE_10
           
static java.util.logging.Level TRACE_16
           
static java.util.logging.Level TRACE_20
           
static java.util.logging.Level TRACE_30
           
static java.util.logging.Level TRACE_32
           

 

Constructor Summary
OracleLog()
           

 

Method Summary
static java.lang.String argument()
           
static java.lang.String argument(boolean x)
           
static java.lang.String argument(byte x)
           
static java.lang.String argument(double x)
           
static java.lang.String argument(float x)
           
static java.lang.String argument(int x)
           
static java.lang.String argument(long x)
           
static java.lang.String argument(java.lang.Object x)
           
static java.lang.String argument(short x)
           
static byte[] charsToUcs2Bytes(char[] chars, int nchars, int offset)
          Deprecated. when using jdk 1.4. Use java.util.logging instead.
static boolean isDebugZip()
          Check if the Oracle Jdbc zip/jar file being used has the logging facility avaliable.
static boolean isEnabled()
          Check if logging is enabled.
static boolean registerClassNameAndGetCurrentTraceSetting(java.lang.Class classObj)
           
static void setTrace(boolean enable)
          Set the tracing enable variable.
static void setupFromSystemProperties()
          This method uses System.getProperty() to read properties to control logging.
static java.lang.String toHex(byte value)
           
static java.lang.String toHex(byte[] value)
           
static java.lang.String toHex(byte[] value, int length)
           
static java.lang.String toHex(int value)
           
static java.lang.String toHex(long value, int bytes)
           
static java.lang.String toHex(short value)
           

 

Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait

 

Field Detail

TRACE

public static final boolean TRACE
See Also:
Constant Field Values

INTERNAL_ERROR

public static final java.util.logging.Level INTERNAL_ERROR

TRACE_1

public static final java.util.logging.Level TRACE_1

TRACE_10

public static final java.util.logging.Level TRACE_10

TRACE_16

public static final java.util.logging.Level TRACE_16

TRACE_20

public static final java.util.logging.Level TRACE_20

TRACE_30

public static final java.util.logging.Level TRACE_30

TRACE_32

public static final java.util.logging.Level TRACE_32

Constructor Detail

OracleLog

public OracleLog()

Method Detail

isDebugZip

public static boolean isDebugZip()
Check if the Oracle Jdbc zip/jar file being used has the logging facility avaliable. Note that the logging facility is only available in the debug zip/jar files.
Returns:
true if a debug zip/jar file is being used, or false if not.

isEnabled

public static boolean isEnabled()
Check if logging is enabled.
Returns:
true if logging is enabled, or false if not.

registerClassNameAndGetCurrentTraceSetting

public static boolean registerClassNameAndGetCurrentTraceSetting(java.lang.Class classObj)

setTrace

public static void setTrace(boolean enable)
Set the tracing enable variable.

setupFromSystemProperties

public static void setupFromSystemProperties()
This method uses System.getProperty() to read properties to control logging. Properties are not available in an applet environment or whenver security setting prevent it.

argument

public static java.lang.String argument()

argument

public static java.lang.String argument(boolean x)

argument

public static java.lang.String argument(byte x)

argument

public static java.lang.String argument(short x)

argument

public static java.lang.String argument(int x)

argument

public static java.lang.String argument(long x)

argument

public static java.lang.String argument(float x)

argument

public static java.lang.String argument(double x)

argument

public static java.lang.String argument(java.lang.Object x)

charsToUcs2Bytes

public static byte[] charsToUcs2Bytes(char[] chars,
                                      int nchars,
                                      int offset)
Deprecated. when using jdk 1.4. Use java.util.logging instead.

toHex

public static java.lang.String toHex(long value,
                                     int bytes)

toHex

public static java.lang.String toHex(byte value)

toHex

public static java.lang.String toHex(short value)

toHex

public static java.lang.String toHex(int value)

toHex

public static java.lang.String toHex(byte[] value,
                                     int length)

toHex

public static java.lang.String toHex(byte[] value)

Skip navigation links

Oracle Database JDBC Java API Reference
11g Release 2

E13995-03


Copyright © 2009, Oracle and/or its affiliates. All rights reserved.