| 1 |
package application.helloworld; |
| 2 |
// be: packages |
| 3 |
import java.util.Locale; |
| 4 |
import java.util.MissingResourceException; |
| 5 |
import java.util.ResourceBundle; |
| 6 |
// ee: packages |
| 7 |
// be: introductory comment |
| 8 |
/** |
| 9 |
* HelloWorld.java |
| 10 |
* |
| 11 |
* |
| 12 |
* <br> |
| 13 |
* Created: : 2007/04/12 11:24:48$ |
| 14 |
* |
| 15 |
* @author <a href="mailto:N.N_(at)_fh-aachen.de">N.N.</a> |
| 16 |
* @version : 0.0$ |
| 17 |
*/ |
| 18 |
// ee: introductory comment |
| 19 |
// be: class declaration |
| 20 |
public class HelloWorld |
| 21 |
// ee: class declaration |
| 22 |
{ |
| 23 |
// be: specific constructor |
| 24 |
public HelloWorld() |
| 25 |
{ |
| 26 |
System.out.println("Object HelloWorld created"); |
| 27 |
} // end of specific constructor "HelloWorld()" |
| 28 |
// ee: specific constructor |
| 29 |
|
| 30 |
public static final void main(final String[] args) |
| 31 |
{ |
| 32 |
String baseName = "HelloWorld"; |
| 33 |
// ee: using the resource bundle |
| 34 |
ResourceBundle rb = ResourceBundle.getBundle(baseName); |
| 35 |
String greetings = rb.getString("hello_msg"); |
| 36 |
// ee: using the resource bundle |
| 37 |
System.out.printf("%s\n", greetings); |
| 38 |
} // end of method "main(String[] args)" |
| 39 |
} // end of class "HelloWorld" |