|
Holger's Java API |
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectjava.util.ResourceBundle
java.util.ListResourceBundle
com.antelmann.util.FormattedResourceBundle
public class FormattedResourceBundle
a ResourceBundle that gets its content from a specially formatted file, supporting different encodings, in particular UTF8 for global support.
| Nested Class Summary |
|---|
| Nested classes/interfaces inherited from class java.util.ResourceBundle |
|---|
ResourceBundle.Control |
| Field Summary | |
|---|---|
protected String |
charset
encoding used |
protected Object[][] |
contents
|
protected String |
fieldSeparator
separates the key from the value |
protected MyFile |
file
denotes the underlying file |
protected String |
recordSeparator
separates each entry |
| Fields inherited from class java.util.ResourceBundle |
|---|
parent |
| Constructor Summary | |
|---|---|
FormattedResourceBundle(File file,
String fieldSeparator)
uses carriage return and new line as record separator and UTF8 as charset. |
|
FormattedResourceBundle(InputStream stream,
String fieldSeparator,
String recordSeparator,
String charset)
|
|
FormattedResourceBundle(Reader reader,
String fieldSeparator,
String recordSeparator)
uses # as comment indicator |
|
FormattedResourceBundle(Reader reader,
String fieldSeparator,
String recordSeparator,
String commentIndicator)
|
|
FormattedResourceBundle(URL url,
String fieldSeparator)
uses the platform dependent line break as record separator and UTF8 as charset. |
|
| Method Summary | |
|---|---|
static void |
exportResourceBundle(ResourceBundle bundle,
File file,
String fieldSeparator)
uses the platform-dependent line break as record separator and UTF8 as charset. |
protected Object[][] |
getContents()
|
static DefaultTableModel |
makeTableModel(ResourceBundle reference,
ResourceBundle... other)
creates a table for allowing a visualized comparison between resource bundles |
static ResourceBundle |
merge(ResourceBundle... bundles)
|
| Methods inherited from class java.util.ListResourceBundle |
|---|
getKeys, handleGetObject, handleKeySet |
| Methods inherited from class java.util.ResourceBundle |
|---|
clearCache, clearCache, containsKey, getBundle, getBundle, getBundle, getBundle, getBundle, getBundle, getLocale, getObject, getString, getStringArray, keySet, setParent |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Field Detail |
|---|
protected MyFile file
protected String fieldSeparator
protected String recordSeparator
protected String charset
protected Object[][] contents
| Constructor Detail |
|---|
public FormattedResourceBundle(File file,
String fieldSeparator)
throws IOException
IOException
public FormattedResourceBundle(URL url,
String fieldSeparator)
throws IOException
IOException
public FormattedResourceBundle(InputStream stream,
String fieldSeparator,
String recordSeparator,
String charset)
throws IOException
IOException
public FormattedResourceBundle(Reader reader,
String fieldSeparator,
String recordSeparator)
throws IOException
IOException
public FormattedResourceBundle(Reader reader,
String fieldSeparator,
String recordSeparator,
String commentIndicator)
throws IOException
IOException| Method Detail |
|---|
protected Object[][] getContents()
getContents in class ListResourceBundle
public static void exportResourceBundle(ResourceBundle bundle,
File file,
String fieldSeparator)
throws IOException
IOException
public static DefaultTableModel makeTableModel(ResourceBundle reference,
ResourceBundle... other)
public static ResourceBundle merge(ResourceBundle... bundles)
|
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||