Oracle Data-aware Controls Reference

oracle.dacf.dataset
Class ExceptionProcessor

java.lang.Object
  extended byoracle.dacf.dataset.ExceptionProcessor

public class ExceptionProcessor
extends java.lang.Object

A single instance that encapsulates generic and database access exceptions in ErrorMessages and posts these error messages to the ErrorManager.

When the ExceptionProcessor is invoked, it notifies all registerd listeners that an exception is going to be processed. Each of the notified error listeners has the option of vetoing the exception processing.

The ExceptionProcessor also administers the registration of ExceptionProcessorListeners.

Version:
SDK
See Also:
ExceptionProcessorEvent, ExceptionProcessorListener, ErrorManager, ErrorMessage

Constructor Summary
protected ExceptionProcessor()
          Protected constructor.
 
Method Summary
static void addExceptionProcessorListener(ExceptionProcessorListener epl)
          Registers a listener with the ExceptionProcessor; only registered listeners are eligible to be notified by the ErrorProcessor of error events.
protected static ExceptionProcessorListener[] getListeners()
          Returns the list of the listeners currently registered with the ExceptionProcessor.
static void processCSException(javax.infobus.DataItem dataItem, int rowNum, oracle.jbo.JboException csExcept)
          Processes a Java Business Objects-specific exception using the default error type and severity.
static void processCSException(javax.infobus.DataItem dataItem, int rowNum, oracle.jbo.JboException csExcept, ErrorType type, ErrorSeverity severity)
          Processes a Java Business Objects-specific exception using a specified error type and severity.
static void processException(javax.infobus.DataItem dataItem, int rowNum, java.lang.Exception except)
          Processes a generic exception using the default error type and severity.
static void processException(javax.infobus.DataItem dataItem, int rowNum, java.lang.Exception except, ErrorType type, ErrorSeverity severity)
          A method to process a generic exception which also specifies an error type and severity.
static void removeExceptionProcessorListener(ExceptionProcessorListener epl)
          Unregisters an error listener; unregistered listeners are not notified of error events by the ErrorProcessor.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ExceptionProcessor

protected ExceptionProcessor()
Protected constructor.

Method Detail

processException

public static void processException(javax.infobus.DataItem dataItem,
                                    int rowNum,
                                    java.lang.Exception except)
Processes a generic exception using the default error type and severity.

This method notifies all listeners about the occurence of the exception and eventually stores the exception with the ErrorManager. The exception is processed using the default type and severity.

Parameters:
dataItem - the DataItem to which the exception is related.
rowNum - the row in the DataItem where the exception occured.
except - the exception object thrown.
See Also:
ExceptionProcessorEvent, ExceptionProcessorListener, ErrorManager, ErrorMessage

processException

public static void processException(javax.infobus.DataItem dataItem,
                                    int rowNum,
                                    java.lang.Exception except,
                                    ErrorType type,
                                    ErrorSeverity severity)
A method to process a generic exception which also specifies an error type and severity.

The method notifies all listeners about the occurence of the exception and eventually stores the exception with the ErrorManager.

Parameters:
dataItem - the DataItem to which the exception is related.
rowNum - the row in the DataItem where the exception occured.
except - the exception object thrown.
type - the ErrorMessage type to be assigned to the exception.
severity - the ErrorMessage severity to be assigned to the exception.
See Also:
ExceptionProcessorEvent, ExceptionProcessorListener, ErrorManager, ErrorMessage

processCSException

public static void processCSException(javax.infobus.DataItem dataItem,
                                      int rowNum,
                                      oracle.jbo.JboException csExcept)
Processes a Java Business Objects-specific exception using the default error type and severity.

This method notifies all listeners about the occurence of the exception and eventually stores the exception with the ErrorManager. The exception is processed using the default type and severity.

Parameters:
dataItem - the DataItem to which the exception is related.
rowNum - the row in the DataItem where the exception occured.
csExcept - the database access exception object thrown.
See Also:
ExceptionProcessorEvent, ExceptionProcessorListener, ErrorManager, ErrorMessage

processCSException

public static void processCSException(javax.infobus.DataItem dataItem,
                                      int rowNum,
                                      oracle.jbo.JboException csExcept,
                                      ErrorType type,
                                      ErrorSeverity severity)
Processes a Java Business Objects-specific exception using a specified error type and severity.

This method notifies all listeners about the occurence of the exception and eventually stores the exception with the ErrorManager.

Parameters:
dataItem - the DataItem to which the exception is related.
rowNum - the row in the DataItem where the exception occured.
csExcept - the database access exception object thrown.
type - the ErrorMessage type to be assigned to the exception.
severity - the ErrorMessage severity to be assigned to the exception.
See Also:
ExceptionProcessorEvent, ExceptionProcessorListener, ErrorManager, ErrorMessage

addExceptionProcessorListener

public static void addExceptionProcessorListener(ExceptionProcessorListener epl)
Registers a listener with the ExceptionProcessor; only registered listeners are eligible to be notified by the ErrorProcessor of error events.

Parameters:
epl - an error listener.

removeExceptionProcessorListener

public static void removeExceptionProcessorListener(ExceptionProcessorListener epl)
Unregisters an error listener; unregistered listeners are not notified of error events by the ErrorProcessor.

Parameters:
epl - an error listener.

getListeners

protected static ExceptionProcessorListener[] getListeners()
Returns the list of the listeners currently registered with the ExceptionProcessor.

Returns:
the array of ExceptionProcessorListeners registered with the ExceptionProcessor.

Oracle Data-aware Controls Reference

 

Copyright © 1997, 2003, Oracle. All rights reserved.