Public Member Functions

alma.acsexmplErrorComponent.ErrorComponentImpl.ErrorComponentImpl Class Reference

Inheritance diagram for alma.acsexmplErrorComponent.ErrorComponentImpl.ErrorComponentImpl:
alma.acs.component.ComponentImplBase alma.acs.component.ComponentLifecycle

List of all members.

Public Member Functions

void displayMessage ()
void badMethod (short depth) throws GenericErrorEx
void corbaSystemException () throws org.omg.CORBA.SystemException
void exceptionFromCompletion (short depth) throws GenericErrorEx
void typeException (short depth) throws ACSErrTypeCommonEx
Completion completionFromException (short depth)
Completion completionFromCompletion (short depth)
Completion completionOnStack (short depth)
void outCompletion (alma.ACSErr.CompletionHolder comp)
void generateSIGFPE (short way)
void generateSIGSEGV (short way)
void sleepingCmd (short nbSeconds)

Detailed Description

Implementation of the ErrorComponent interface, which should demonstrate proper use of the ACS error system in Java.

Note on logging: unlike in the C++ implementation of this component, here we do not log the invocation of every method, because the Java container does this automatically. In general the component should only trace the invocations itself if it needs to add custom data to the log.

Author:
hsommer

Member Function Documentation

void alma.acsexmplErrorComponent.ErrorComponentImpl.ErrorComponentImpl.badMethod ( short  depth  )  throws GenericErrorEx

An intentionally bad method that throws an exception (GenericErrorEx) if depth > 0. This exception has causing exception if depth > 1. All exceptions get added to the ErrorTrace list which will transport them over CORBA.

Note that the thrown CORBA exception GenericErrorEx only acts as a vehicle for the embedded ErrorTrace linked list which contains the real data of the exception(s).

See also:
alma.acsexmplErrorComponent.ErrorComponentOperations.badMethod(short)
Completion alma.acsexmplErrorComponent.ErrorComponentImpl.ErrorComponentImpl.completionFromCompletion ( short  depth  ) 
See also:
alma.acsexmplErrorComponent.ErrorComponentOperations.completionFromCompletion(short)

References alma.acs.exceptions.AcsJCompletion.toCorbaCompletion().

Completion alma.acsexmplErrorComponent.ErrorComponentImpl.ErrorComponentImpl.completionFromException ( short  depth  ) 
See also:
alma.acsexmplErrorComponent.ErrorComponentOperations.completionFromException(short)

References alma.acs.exceptions.AcsJCompletion.toCorbaCompletion().

Referenced by alma.acsexmplErrorComponent.ErrorComponentImpl.ErrorComponentImpl.completionOnStack().

Completion alma.acsexmplErrorComponent.ErrorComponentImpl.ErrorComponentImpl.completionOnStack ( short  depth  ) 

Forwards to completionFromException(short) because in Java we can't create objects on the stack, so there is no distinction to be made.

See also:
alma.acsexmplErrorComponent.ErrorComponentOperations.completionOnStack(short)

References alma.acsexmplErrorComponent.ErrorComponentImpl.ErrorComponentImpl.completionFromException().

void alma.acsexmplErrorComponent.ErrorComponentImpl.ErrorComponentImpl.corbaSystemException (  )  throws org.omg.CORBA.SystemException

An intentionally bad method that throws a CORBA.BAD_PARAM system exception to show how to handle CORBA System Exceptions

See also:
alma.acsexmplErrorComponent.ErrorComponentOperations.corbaSystemException()
void alma.acsexmplErrorComponent.ErrorComponentImpl.ErrorComponentImpl.displayMessage (  ) 
void alma.acsexmplErrorComponent.ErrorComponentImpl.ErrorComponentImpl.exceptionFromCompletion ( short  depth  )  throws GenericErrorEx

This method throws a GenericErrorEx exception if the completion returned from internalCompletionMethod(int) has an associated exception. This will be the case if the depth parameter is > 0.

See also:
alma.acsexmplErrorComponent.ErrorComponentOperations.exceptionFromCompletion(short)

References alma.acs.exceptions.AcsJCompletion.getAcsJException(), and alma.acs.exceptions.AcsJCompletion.isError().

void alma.acsexmplErrorComponent.ErrorComponentImpl.ErrorComponentImpl.generateSIGFPE ( short  way  ) 
void alma.acsexmplErrorComponent.ErrorComponentImpl.ErrorComponentImpl.generateSIGSEGV ( short  way  ) 
void alma.acsexmplErrorComponent.ErrorComponentImpl.ErrorComponentImpl.outCompletion ( alma.ACSErr.CompletionHolder  comp  ) 

this method returns a Completion as an out parameter.

See also:
alma.acsexmplErrorComponent.ErrorComponentOperations.outCompletion(alma.ACSErr.CompletionHolder)
void alma.acsexmplErrorComponent.ErrorComponentImpl.ErrorComponentImpl.sleepingCmd ( short  nbSeconds  ) 
void alma.acsexmplErrorComponent.ErrorComponentImpl.ErrorComponentImpl.typeException ( short  depth  )  throws ACSErrTypeCommonEx

The documentation for this class was generated from the following file:
 All Classes Namespaces Files Functions Variables Enumerations Properties