Overview | Package | Class | Use | Tree | Deprecated | Index | Help
| Business Components
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## oracle.jbo.common
Interface JboMessage

All Known Implementing Classes:
  JboException, JboWarning

public interface JboMessage

Defines methods for localizing exception messages for various target languages, and for message formatting.

Message-text localization occurs when the client calls `getLocalizedMessage()`, rather than at the time the exception occurs, because the client may need to present the message in a number of different languages.

Since:
  JDeveloper 3.0

Method Summary
`void` | `addToDetails(java.lang.Object obj)` Adds to the list of details.
`java.lang.String` | `getBaseMessage()` Gets the message without localizing it or inserting parameters.
`java.lang.String` | `getDetailMessage()` Converts the message to text, incorporating the list of details.
`java.lang.Object[]` | `getDetails()` Gets the list of objects and exceptions that spawned this message.
`java.lang.String` | `getErrorCode()` Gets the message's error code.
`java.lang.Object[]` | `getErrorParameters()` Gets the message's parameters.
`java.lang.String` | `getLocalizedBaseMessage(java.util.Locale l)` Localizes an un-parameterized message text for a specific `Locale`.
`java.lang.String` | `getLocalizedMessage(java.util.Locale l)` Formats the message text for a specific `Locale`.
`java.lang.String` | `getMessage()` Formats the message text for the default locale.
`java.lang.String` | `getProductCode()` Gets the product code.
`java.lang.Class` | `getResourceClass()` Gets the resource bundle used to localize messages.
`java.lang.String` | `getResourceName()` Gets the name of the `ResourceBundle` used to localize messages.
`boolean` | `isLocalizable()` Tests this message's localizability.
`void` | `setDetails(java.lang.Object[] details)` Sets the list of details.

Method Detail

### getMessage

    public java.lang.String getMessage()

  Formats the message text for the default locale.
  Returns:
    the localized message.

### getLocalizedMessage

    public java.lang.String getLocalizedMessage(java.util.Locale l)

  Formats the message text for a specific `Locale`.
  Parameters:
    `l` - a locale.
  Returns:
    the localized message.

### getBaseMessage

    public java.lang.String getBaseMessage()

  Gets the message without localizing it or inserting parameters.
  Returns:
    the un-formatted, non-localized message.

### getLocalizedBaseMessage

    public java.lang.String getLocalizedBaseMessage(java.util.Locale l)

  Localizes an un-parameterized message text for a specific `Locale`.
  Parameters:
    `l` - a locale.
  Returns:
    the localalized but un-formatted message.

### getResourceClass

    public java.lang.Class getResourceClass()

  Gets the resource bundle used to localize messages.
  Returns:
    a `ResourceBundle` subclass.

### getResourceName

    public java.lang.String getResourceName()

  Gets the name of the `ResourceBundle` used to localize messages.
  Returns:
    a string identifying a resource bundle.

### getErrorCode

    public java.lang.String getErrorCode()

  Gets the message's error code.
  Returns:
    a string containing an error code.

### getErrorParameters

    public java.lang.Object[] getErrorParameters()

  Gets the message's parameters.
  Returns:
    an array.

### getProductCode

    public java.lang.String getProductCode()

  Gets the product code.
  Returns:
    this message's product code.

### getDetails

    public java.lang.Object[] getDetails()

  Gets the list of objects and exceptions that spawned this message.
  Returns:
    an array.

### getDetailMessage

    public java.lang.String getDetailMessage()

  Converts the message to text, incorporating the list of details.
  Returns:
    a text string.

### setDetails

    public void setDetails(java.lang.Object[] details)

  Sets the list of details.
  Parameters:
    `details` - an array which replaces the current list of details. array in this exception object.

### addToDetails

    public void addToDetails(java.lang.Object obj)

  Adds to the list of details.
  Parameters:
    `obj` - an object to add to the details list.

### isLocalizable

    public boolean isLocalizable()

  Tests this message's localizability.
  Returns:
    `true` if this message can be localized.

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
| Business Components
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD