private static void dealWithException(Exception e) {
		if (e instanceof SAXParseException) {
			SAXParseException ee = (SAXParseException) e;
			System.out.println("\n** Parsing error" + ", line " + ee.getLineNumber() + ", uri " + ee.getSystemId());
			System.out.println("   " + ee.getMessage());
			Exception x = (ee.getException() == null ? ee : ee.getException());
			x.printStackTrace();
		} else if (e instanceof SAXException) {
			SAXException ee = (SAXException) e;
			Exception x = (ee.getException() == null ? ee : ee.getException());
			x.printStackTrace();
		} else if (e instanceof TransformerConfigurationException) {
			TransformerConfigurationException ee = (TransformerConfigurationException) e;
			System.out.println("\n** Transformer Factory error\n" + e.getMessage());
			Throwable x = (ee.getException() == null ? ee : ee.getException());
			x.printStackTrace();
		} else if (e instanceof TransformerException) {
			TransformerException ee = (TransformerException) e;
			System.out.println("\n** Transformation error" + e.getMessage());
			Throwable x = (ee.getException() == null ? ee : ee.getException());
			x.printStackTrace();
		} else {
			System.out.println(e);
			e.printStackTrace();
		}
		System.exit(1);
	}