< prev index next >

src/java.base/share/classes/java/util/MissingResourceException.java

Print this page




  47  * @author      Mark Davis
  48  * @since       1.1
  49  */
  50 public
  51 class MissingResourceException extends RuntimeException {
  52 
  53     /**
  54      * Constructs a MissingResourceException with the specified information.
  55      * A detail message is a String that describes this particular exception.
  56      * @param s the detail message
  57      * @param className the name of the resource class
  58      * @param key the key for the missing resource.
  59      */
  60     public MissingResourceException(String s, String className, String key) {
  61         super(s);
  62         this.className = className;
  63         this.key = key;
  64     }
  65 
  66     /**
  67      * Constructs a <code>MissingResourceException</code> with
  68      * <code>message</code>, <code>className</code>, <code>key</code>,
  69      * and <code>cause</code>. This constructor is package private for
  70      * use by <code>ResourceBundle.getBundle</code>.
  71      *
  72      * @param message
  73      *        the detail message
  74      * @param className
  75      *        the name of the resource class
  76      * @param key
  77      *        the key for the missing resource.
  78      * @param cause
  79      *        the cause (which is saved for later retrieval by the
  80      *        {@link Throwable.getCause()} method). (A null value is
  81      *        permitted, and indicates that the cause is nonexistent
  82      *        or unknown.)
  83      */
  84     MissingResourceException(String message, String className, String key, Throwable cause) {
  85         super(message, cause);
  86         this.className = className;
  87         this.key = key;
  88     }
  89 
  90     /**




  47  * @author      Mark Davis
  48  * @since       1.1
  49  */
  50 public
  51 class MissingResourceException extends RuntimeException {
  52 
  53     /**
  54      * Constructs a MissingResourceException with the specified information.
  55      * A detail message is a String that describes this particular exception.
  56      * @param s the detail message
  57      * @param className the name of the resource class
  58      * @param key the key for the missing resource.
  59      */
  60     public MissingResourceException(String s, String className, String key) {
  61         super(s);
  62         this.className = className;
  63         this.key = key;
  64     }
  65 
  66     /**
  67      * Constructs a {@code MissingResourceException} with
  68      * {@code message}, {@code className}, {@code key},
  69      * and {@code cause}. This constructor is package private for
  70      * use by {@code ResourceBundle.getBundle}.
  71      *
  72      * @param message
  73      *        the detail message
  74      * @param className
  75      *        the name of the resource class
  76      * @param key
  77      *        the key for the missing resource.
  78      * @param cause
  79      *        the cause (which is saved for later retrieval by the
  80      *        {@link Throwable.getCause()} method). (A null value is
  81      *        permitted, and indicates that the cause is nonexistent
  82      *        or unknown.)
  83      */
  84     MissingResourceException(String message, String className, String key, Throwable cause) {
  85         super(message, cause);
  86         this.className = className;
  87         this.key = key;
  88     }
  89 
  90     /**


< prev index next >