summaryrefslogtreecommitdiff
path: root/icu4j/samples/src/com/ibm/icu/samples/iuc/Sample30_ResHello.java
blob: 85a71cc4ac8d92d08df5309dbdcb57625f6f658b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
// © 2016 and later: Unicode, Inc. and others.
// License & terms of use: http://www.unicode.org/copyright.html#License
/*
 *******************************************************************************
 * Copyright (C) 2013-2014, International Business Machines Corporation and         *
 * others. All Rights Reserved.                                                *
 *******************************************************************************
 */
package com.ibm.icu.samples.iuc;

import java.util.Locale;

import com.ibm.icu.util.UResourceBundle;

/**
 * @author srl
 *
 */
public class Sample30_ResHello {
    public static void main(String... args) {
        Locale locale = Locale.getDefault();
        UResourceBundle bundle = 
                UResourceBundle.getBundleInstance(
                        Sample30_ResHello.class.getPackage().getName().replace('.', '/')+"/data/reshello",
                        locale,
                        Sample30_ResHello.class.getClassLoader());
        System.out.println(bundle.getString("hello"));
    }
}