Changeset 446 for tapas/common
- Timestamp:
- 04/02/12 17:01:12 (12 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
tapas/common/implementation/com/ether/EtherHelper.java
r423 r446 17 17 import java.util.ArrayList; 18 18 import java.util.List; 19 import java.util.Locale; 19 20 import java.util.Random; 21 import java.util.ResourceBundle; 20 22 21 23 /** … … 226 228 } 227 229 } 230 231 /** 232 * This method return the text corresponding to the code in the files messages**.properties 233 * 234 * @param code 235 * @param locale 236 * @return 237 */ 238 public static String getMessage( @NotNull final String code, @Nullable final Locale locale ) 239 { 240 ResourceBundle bundle = ResourceBundle.getBundle( "messages", Locale.ENGLISH ); 241 if( null != locale ) 242 bundle = ResourceBundle.getBundle( "messages", locale ); 243 244 return bundle.getString( code ); 245 } 246 228 247 }
Note: See TracChangeset
for help on using the changeset viewer.