Oracle Discussions Java API Reference
10g Release 1 (10.1.2)

B25496-01

oracle.discussions.sdk
Class TdMessagingException

oracle.discussions.sdk.TdMessagingException

public class TdMessagingException

Wrapper a TdException into a MessagingException to allow to overwrite javax.mail.* APIs.

Extends from javax.mail.MessagingException which is a base class for all the exception thrown by the java mail messaging operations.

Sample code snipper illustrating the usage of TdMessagingException.

  try
  { 
    //Do some operations.....
  }
  catch (TdException tdEx) 
  {
     throw new TdMessagingException(tdEx);
   }
 
Since:
OCS 10.1.1
See Also:
TdException, in javax.mail package.

Constructor Summary
TdMessagingException(java.lang.Throwable t)
          Takes in a throwable object and constructs a Oracle Discussions specific messaging exception object.

 

Method Summary
 java.lang.String getLocalizedMessage()
          Returns the message formatted as per the default locale.
 java.lang.String getMessage()
          Returns the exception message.
 java.lang.Exception getNextException()
          Sets the next exception in the exception list.
 void printStackTrace()
          Prints the exception stack trace.
 void printStackTrace(java.io.PrintStream ps)
          Prints the exception stack trace to console
 void printStackTrace(java.io.PrintWriter pw)
          Prints the exception stack trace to a file.
 boolean setNextException()
          Sets the next exception in the exception list.
 java.lang.String toString()
          Returns the exception object in the form of a string.

 

Constructor Detail

TdMessagingException

public TdMessagingException(java.lang.Throwable t)
Takes in a throwable object and constructs a Oracle Discussions specific messaging exception object.
Parameters:
t - the throwable object used in constructing the exception

Method Detail

getNextException

public java.lang.Exception getNextException()
Sets the next exception in the exception list. If there are more than one exception thrown by a method, they are returned in the form of a list. The immediate next exception in the list is returned by this method.
Returns:
Exception

setNextException

public boolean setNextException()
Sets the next exception in the exception list. If there are more than one exception thrown by a method, they are stored in the form of a list. The immediate next exception in the list is set by this method.
Returns:
boolean

getMessage

public java.lang.String getMessage()
Returns the exception message.

This method returns the message in english and is not formatted as per the locale.

Returns:
String

getLocalizedMessage

public java.lang.String getLocalizedMessage()
Returns the message formatted as per the default locale.
Returns:
String

printStackTrace

public void printStackTrace()
Prints the exception stack trace.

printStackTrace

public void printStackTrace(java.io.PrintStream ps)
Prints the exception stack trace to console
Parameters:
ps -  

printStackTrace

public void printStackTrace(java.io.PrintWriter pw)
Prints the exception stack trace to a file.
Parameters:
pw -  

toString

public java.lang.String toString()
Returns the exception object in the form of a string. Used in printing the exception to a log file
Returns:
string

Oracle Discussions Java API Reference
10g Release 1 (10.1.2)

B25496-01

Copyright © 2002, 2005, Oracle. All rights reserved.