to top
Android APIs
public class

MissingResourceException

extends RuntimeException
java.lang.Object
   ↳ java.lang.Throwable
     ↳ java.lang.Exception
       ↳ java.lang.RuntimeException
         ↳ java.util.MissingResourceException

Class Overview

A MissingResourceException is thrown by ResourceBundle when a resource bundle cannot be found or a resource is missing from a resource bundle.

Summary

Public Constructors
MissingResourceException(String detailMessage, String className, String resourceName)
Constructs a new MissingResourceException with the stack trace, message, the class name of the resource bundle and the name of the missing resource filled in.
Public Methods
String getClassName()
Returns the class name of the resource bundle from which a resource could not be found, or in the case of a missing resource, the name of the missing resource bundle.
String getKey()
Returns the name of the missing resource, or an empty string if the resource bundle is missing.
[Expand]
Inherited Methods
From class java.lang.Throwable
From class java.lang.Object

Public Constructors

public MissingResourceException (String detailMessage, String className, String resourceName)

Since: API Level 1

Constructs a new MissingResourceException with the stack trace, message, the class name of the resource bundle and the name of the missing resource filled in.

Parameters
detailMessage the detail message for the exception.
className the class name of the resource bundle.
resourceName the name of the missing resource.

Public Methods

public String getClassName ()

Since: API Level 1

Returns the class name of the resource bundle from which a resource could not be found, or in the case of a missing resource, the name of the missing resource bundle.

Returns
  • the class name of the resource bundle.

public String getKey ()

Since: API Level 1

Returns the name of the missing resource, or an empty string if the resource bundle is missing.

Returns
  • the name of the missing resource.