public static void main(String[] args) {
		if (args.length != 2) {
			System.out.println("Invalid parameters!\n" + "Syntax:\n"
					+ "java meketre <result rdf-file> <mapping file>");
			return;
		}

		// check, if the input-files exist
		if (!new File(args[1]).exists()) {
			System.out.println("File \"" + args[1] + "\" does not exist!");
			return;
		}

		String resourceFolder = "src" + File.separator + "main"
				+ File.separator + "resources";
		String[] dumpFiles = {
				resourceFolder + File.separator
						+ "meketre_application_Term.sql",
				resourceFolder + File.separator
						+ "meketre_application_Fragment.sql",
				resourceFolder + File.separator
						+ "meketre_application_Tomb.sql",
				resourceFolder + File.separator
						+ "meketre_application_Theme.sql" };
		
		for (String dumpFile : dumpFiles) {
			if (!new File(dumpFile).exists()) {
				System.out.println("File \"" + dumpFile + "\" does not exist!");
				return;
			}
		}

		List<Item> items = loadData(dumpFiles[0], dumpFiles[1], dumpFiles[2],
				dumpFiles[3]);

		Map<String, String> mapping = getMapping(args[1]);

		for (Item item : items) {
			String meketreUrl = item.getMeketreUrl();
			if (meketreUrl != null) {
				item.setPelagiosUrl(mapping.get(meketreUrl + ".html"));
			}
		}

		writeRDF(args[0], items);
	}