added JavaDocs in Resources.java
This commit is contained in:
@@ -32,14 +32,41 @@ public static String stringLookup(String key) {
|
|||||||
return BUNDLE.getString(key);
|
return BUNDLE.getString(key);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Gets a int for the given key from the resource bundle in {@linkplain #BUNDLE}.
|
||||||
|
*
|
||||||
|
* @param key the key for the desired string
|
||||||
|
* @return the string for the given key
|
||||||
|
* @throws NullPointerException if {@code key} is {@code null}
|
||||||
|
* @throws java.util.MissingResourceException if no object for the given key can be found
|
||||||
|
* @throws ClassCastException if the object found for the given key is not a string
|
||||||
|
*/
|
||||||
public static int intLookup(String key) {
|
public static int intLookup(String key) {
|
||||||
return Integer.parseInt(BUNDLE.getString(key));
|
return Integer.parseInt(BUNDLE.getString(key));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Gets a boolean for the given key from the resource bundle in {@linkplain #BUNDLE}.
|
||||||
|
*
|
||||||
|
* @param key the key for the desired string
|
||||||
|
* @return the string for the given key
|
||||||
|
* @throws NullPointerException if {@code key} is {@code null}
|
||||||
|
* @throws java.util.MissingResourceException if no object for the given key can be found
|
||||||
|
* @throws ClassCastException if the object found for the given key is not a string
|
||||||
|
*/
|
||||||
public static boolean boolLookup(String key) {
|
public static boolean boolLookup(String key) {
|
||||||
return Boolean.parseBoolean(BUNDLE.getString(key));
|
return Boolean.parseBoolean(BUNDLE.getString(key));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Gets a double for the given key from the resource bundle in {@linkplain #BUNDLE}.
|
||||||
|
*
|
||||||
|
* @param key the key for the desired string
|
||||||
|
* @return the string for the given key
|
||||||
|
* @throws NullPointerException if {@code key} is {@code null}
|
||||||
|
* @throws java.util.MissingResourceException if no object for the given key can be found
|
||||||
|
* @throws ClassCastException if the object found for the given key is not a string
|
||||||
|
*/
|
||||||
public static double doubleLookup(String key) {
|
public static double doubleLookup(String key) {
|
||||||
return Double.parseDouble(BUNDLE.getString(key));
|
return Double.parseDouble(BUNDLE.getString(key));
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user