// Path: src/org/forecat/console/utils/UtilsConsole.java
// public class UtilsConsole {
// 	public static InputStream openFile(String file) {
// 		InputStream ret = null;
// 
// 		ret = Main.class.getResourceAsStream(file);
// 
// 		if (ret == null) {
// 			try {
// 				ret = new FileInputStream(file);
// 			} catch (FileNotFoundException e) {
// 				// TODO Auto-generated catch block
// 				e.printStackTrace();
// 			}
// 		}
// 
// 		return ret;
// 	}
// 
// 	public static Integer multiMax(Integer a, Integer... b) {
// 		for (Integer i : b) {
// 			a = Math.max(a, i);
// 		}
// 
// 		return a;
// 	}
// }


import java.io.BufferedReader;
import java.io.DataInputStream;
import java.io.IOException;
import java.io.InputStream;
import java.io.InputStreamReader;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import org.apache.commons.collections4.map.MultiValueMap;
import org.forecat.console.utils.UtilsConsole;
import org.forecat.shared.translation.SourceSegment;
				continue;
			}
			sourceWord = sourceSplit[i];
			targetWord = targetSplit[i];

			if (Character.isUpperCase(sourceWord.charAt(0))) {
				if (sourceWord.length() > 1 && Character.isUpperCase(sourceWord.charAt(1))
						|| targetWord.length() == 0) {
					sb.append(targetWord.toUpperCase());
				} else {
					sb.append(Character.toUpperCase(targetWord.charAt(0)));
					sb.append(targetWord.substring(1));
				}
			} else {
				sb.append(targetWord);
			}
		}

		return sb.toString();
	}

	public static void loadSegments(String slang, String tlang) throws IOException {
		InputStream sSource = null, tSource = null;
		String sSeg, tSeg;
		BufferedReader sBr, tBr;
		String lang = slang + "-" + tlang;
		// String ordLang = slang.compareTo(tlang) < 0 ? slang + "-" + tlang : tlang + "-" + slang;
		HashMap<String, String> auxSegments = new HashMap<String, String>();
		if (!segments.containsKey(lang)) {

// Path: src/org/forecat/console/utils/UtilsConsole.java
// public class UtilsConsole {
// 	public static InputStream openFile(String file) {
// 		InputStream ret = null;
// 
// 		ret = Main.class.getResourceAsStream(file);
// 
// 		if (ret == null) {
// 			try {
// 				ret = new FileInputStream(file);
// 			} catch (FileNotFoundException e) {
// 				// TODO Auto-generated catch block
// 				e.printStackTrace();
// 			}
// 		}
// 
// 		return ret;
// 	}
// 
// 	public static Integer multiMax(Integer a, Integer... b) {
// 		for (Integer i : b) {
// 			a = Math.max(a, i);
// 		}
// 
// 		return a;
// 	}
// }


// Path: src/org/forecat/server/translation/cachetrans/Cachetrans.java
import java.io.BufferedReader;
import java.io.DataInputStream;
import java.io.IOException;
import java.io.InputStream;
import java.io.InputStreamReader;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import org.apache.commons.collections4.map.MultiValueMap;
import org.forecat.console.utils.UtilsConsole;
import org.forecat.shared.translation.SourceSegment;

				continue;
			}
			sourceWord = sourceSplit[i];
			targetWord = targetSplit[i];

			if (Character.isUpperCase(sourceWord.charAt(0))) {
				if (sourceWord.length() > 1 && Character.isUpperCase(sourceWord.charAt(1))
						|| targetWord.length() == 0) {
					sb.append(targetWord.toUpperCase());
				} else {
					sb.append(Character.toUpperCase(targetWord.charAt(0)));
					sb.append(targetWord.substring(1));
				}
			} else {
				sb.append(targetWord);
			}
		}

		return sb.toString();
	}

	public static void loadSegments(String slang, String tlang) throws IOException {
		InputStream sSource = null, tSource = null;
		String sSeg, tSeg;
		BufferedReader sBr, tBr;
		String lang = slang + "-" + tlang;
		// String ordLang = slang.compareTo(tlang) < 0 ? slang + "-" + tlang : tlang + "-" + slang;
		HashMap<String, String> auxSegments = new HashMap<String, String>();
		if (!segments.containsKey(lang)) {

			InputStream config = UtilsConsole.openFile(configFile);