package org.languagetool.gui;

import org.languagetool.JLanguageTool;

import java.util.MissingResourceException;
import java.util.ResourceBundle;

public class Messages {

	private static final ResourceBundle RESOURCE_BUNDLE = ResourceBundle
			.getBundle(JLanguageTool.MESSAGE_BUNDLE);
  
	private Messages() {
	}

	public static String getString(String key) {
		try {
			return RESOURCE_BUNDLE.getString(key);
		} catch (MissingResourceException e) {
			return '!' + key + '!';
		}
	}
}

@@ -1,8 +1,861 @@
+/* LanguageTool, a natural language style checker%0D%0A * Copyright (C) 2011 Marcin Mi%C5%82kowski%0D%0A *%0D%0A * This library is free software; you can redistribute it and/or%0D%0A * modify it under the terms of the GNU Lesser General Public%0D%0A * License as published by the Free Software Foundation; either%0D%0A * version 2.1 of the License, or (at your option) any later version.%0D%0A *%0D%0A * This library is distributed in the hope that it will be useful,%0D%0A * but WITHOUT ANY WARRANTY; without even the implied warranty of%0D%0A * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU%0D%0A * Lesser General Public License for more details.%0D%0A *%0D%0A * You should have received a copy of the GNU Lesser General Public%0D%0A * License along with this library; if not, write to the Free Software%0D%0A * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301%0D%0A * USA%0D%0A */%0D%0A
 package 
@@ -1028,17 +1028,18 @@
 es %7B%0D%0A%0D%0A
-%09
+  
 private 
@@ -1100,19 +1100,26 @@
 Bundle%0D%0A
-%09%09%09
+          
 .getBund
@@ -1157,13 +1157,12 @@
 );%0D%0A
+%0D%0A
   
-%0D%0A%09
 priv
@@ -1183,15 +1183,17 @@
  %7B%0D%0A
-%09
+  
 %7D%0D%0A%0D%0A
-%09
+  
 publ
@@ -1238,20 +1238,25 @@
  %7B%0D%0A
-%09%09
+    
 try %7B%0D%0A
-%09%09%09
+      
 retu
@@ -1291,18 +1291,20 @@
 (key);%0D%0A
-%09%09
+    
 %7D catch 
@@ -1339,11 +1339,14 @@
  %7B%0D%0A
-%09%09%09
+      
 retu
@@ -1370,14 +1370,17 @@
 ';%0D%0A
-%09%09%7D%0D%0A%09
+    %7D%0D%0A  
 %7D%0D%0A%7D

add missing license header; whitespace cleanup (tab -> spaces)