Module org.hsqldb
Package org.hsqldb.lib

## Class ValidatingResourceBundle

- java.lang.Object
- - org.hsqldb.lib.ValidatingResourceBundle

-     public class ValidatingResourceBundle
      extends java.lang.Object

  Purpose of this class is to wrap a RefCapablePropertyResourceBundle to reliably detect any possible use of a missing property key as soon as this class is clinitted. The reason for this is to allow us developers to detect all such errors before end-users ever use this class. See SqltoolRB for an example implementation of this abstract class.

- - ### Field Summary

    Fields
    Modifier and Type | Field | Description
    --- | --- | ---
    `static int` | `EMPTYSTRING_BEHAVIOR` |
    `static int` | `NOOP_BEHAVIOR` |
    `static int` | `THROW_BEHAVIOR` |

  - ### Constructor Summary

    Constructors
    Constructor | Description
    --- | ---
    `ValidatingResourceBundle​(java.lang.String baseName, java.lang.Class<? extends java.lang.Enum<?>> enumType)` |

  - ### Method Summary

    All Methods Static Methods Instance Methods Concrete Methods
    Modifier and Type | Method | Description
    --- | --- | ---
    `java.lang.String` | `getExpandedString​(java.lang.Enum<?> key)` |
    `java.lang.String` | `getExpandedString​(java.lang.Enum<?> key, java.lang.String... strings)` |
    `int` | `getMissingPosValueBehavior()` |
    `int` | `getMissingPropertyBehavior()` |
    `java.lang.String` | `getString​(java.lang.Enum<?> key)` |
    `java.lang.String` | `getString​(java.lang.Enum<?> key, int i1)` |
    `java.lang.String` | `getString​(java.lang.Enum<?> key, int i1, int i2)` |
    `java.lang.String` | `getString​(java.lang.Enum<?> key, int i1, int i2, int i3)` |
    `java.lang.String` | `getString​(java.lang.Enum<?> key, int i1, int i2, java.lang.String s3)` |
    `java.lang.String` | `getString​(java.lang.Enum<?> key, int i1, java.lang.String s2)` |
    `java.lang.String` | `getString​(java.lang.Enum<?> key, int i1, java.lang.String s2, int i3)` |
    `java.lang.String` | `getString​(java.lang.Enum<?> key, int i1, java.lang.String s2, java.lang.String s3)` |
    `java.lang.String` | `getString​(java.lang.Enum<?> key, java.lang.String... strings)` |
    `java.lang.String` | `getString​(java.lang.Enum<?> key, java.lang.String s1, int i2)` |
    `java.lang.String` | `getString​(java.lang.Enum<?> key, java.lang.String s1, int i2, int i3)` |
    `java.lang.String` | `getString​(java.lang.Enum<?> key, java.lang.String s1, int i2, java.lang.String s3)` |
    `java.lang.String` | `getString​(java.lang.Enum<?> key, java.lang.String s1, java.lang.String s2, int i3)` |
    `static java.lang.String` | `resourceKeyFor​(java.lang.Enum<?> enumKey)` |
    `void` | `setMissingPosValueBehavior​(int missingPosValueBehavior)` | Set behavior for get*String(String, String[]) method when a positional index (like %{4}) is used but no subs value was given for that index.
    `void` | `setMissingPropertyBehavior​(int missingPropertyBehavior)` | Set behavior for get*String*() method when a referred-to System Property is not set.
    `void` | `validate()` |

    - ### Methods inherited from class java.lang.Object

      `equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

- - ### Field Detail

    - #### THROW_BEHAVIOR

          public static final int THROW_BEHAVIOR

      See Also:
        Constant Field Values

    - #### EMPTYSTRING_BEHAVIOR

          public static final int EMPTYSTRING_BEHAVIOR

      See Also:
        Constant Field Values

    - #### NOOP_BEHAVIOR

          public static final int NOOP_BEHAVIOR

      See Also:
        Constant Field Values

  - ### Constructor Detail

    - #### ValidatingResourceBundle

          public ValidatingResourceBundle​(java.lang.String baseName,
                                          java.lang.Class<? extends java.lang.Enum<?>> enumType)

  - ### Method Detail

    - #### resourceKeyFor

          public static java.lang.String resourceKeyFor​(java.lang.Enum<?> enumKey)

    - #### getString

          public java.lang.String getString​(java.lang.Enum<?> key)

      See Also:
        `RefCapablePropertyResourceBundle.getString(String)`

    - #### getString

          public java.lang.String getString​(java.lang.Enum<?> key,
                                            java.lang.String... strings)

      See Also:
        `RefCapablePropertyResourceBundle.getString(String, String[], int)`

    - #### getExpandedString

          public java.lang.String getExpandedString​(java.lang.Enum<?> key)

      See Also:
        `RefCapablePropertyResourceBundle.getExpandedString(String, int)`

    - #### getExpandedString

          public java.lang.String getExpandedString​(java.lang.Enum<?> key,
                                                    java.lang.String... strings)

      See Also:
        `RefCapablePropertyResourceBundle.getExpandedString(String, String[], int, int)`

    - #### setMissingPropertyBehavior

          public void setMissingPropertyBehavior​(int missingPropertyBehavior)

      Set behavior for get*String*() method when a referred-to System Property is not set. Set to one of
      - RefCapablePropertyResourceBundle.THROW_BEHAVIOR
      - RefCapablePropertyResourceBundle.EMPTYSTRING_BEHAVIOR
      - RefCapablePropertyResourceBundle.NOOP_BEHAVIOR
      The first value is the default.

    - #### setMissingPosValueBehavior

          public void setMissingPosValueBehavior​(int missingPosValueBehavior)

      Set behavior for get*String(String, String[]) method when a positional index (like %{4}) is used but no subs value was given for that index. Set to one of
      - RefCapablePropertyResourceBundle.THROW_BEHAVIOR
      - RefCapablePropertyResourceBundle.EMPTYSTRING_BEHAVIOR
      - RefCapablePropertyResourceBundle.NOOP_BEHAVIOR
      The first value is the default.

    - #### getMissingPropertyBehavior

          public int getMissingPropertyBehavior()

    - #### getMissingPosValueBehavior

          public int getMissingPosValueBehavior()

    - #### validate

          public void validate()

    - #### getString

          public java.lang.String getString​(java.lang.Enum<?> key,
                                            int i1)

    - #### getString

          public java.lang.String getString​(java.lang.Enum<?> key,
                                            int i1,
                                            int i2)

    - #### getString

          public java.lang.String getString​(java.lang.Enum<?> key,
                                            int i1,
                                            int i2,
                                            int i3)

    - #### getString

          public java.lang.String getString​(java.lang.Enum<?> key,
                                            int i1,
                                            java.lang.String s2)

    - #### getString

          public java.lang.String getString​(java.lang.Enum<?> key,
                                            java.lang.String s1,
                                            int i2)

    - #### getString

          public java.lang.String getString​(java.lang.Enum<?> key,
                                            int i1,
                                            int i2,
                                            java.lang.String s3)

    - #### getString

          public java.lang.String getString​(java.lang.Enum<?> key,
                                            int i1,
                                            java.lang.String s2,
                                            int i3)

    - #### getString

          public java.lang.String getString​(java.lang.Enum<?> key,
                                            java.lang.String s1,
                                            int i2,
                                            int i3)

    - #### getString

          public java.lang.String getString​(java.lang.Enum<?> key,
                                            int i1,
                                            java.lang.String s2,
                                            java.lang.String s3)

    - #### getString

          public java.lang.String getString​(java.lang.Enum<?> key,
                                            java.lang.String s1,
                                            java.lang.String s2,
                                            int i3)

    - #### getString

          public java.lang.String getString​(java.lang.Enum<?> key,
                                            java.lang.String s1,
                                            int i2,
                                            java.lang.String s3)