* Copyright (C) 2017 AT&T Intellectual Property. All rights reserved.
* Copyright (C) 2017 Huawei Technologies Co., Ltd. All rights reserved.
* ================================================================================
+ * Modifications Copyright (c) 2019 Samsung
+ * ================================================================================
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
package org.onap.so.bpmn.core.xml;
-import java.io.FileNotFoundException;
import java.io.IOException;
import java.io.InputStream;
import java.io.InputStreamReader;
import javax.xml.xpath.XPathFactory;
import org.apache.commons.lang3.StringEscapeUtils;
-import org.onap.so.logger.MsoLogger;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
import org.w3c.dom.Document;
-import org.w3c.dom.NamedNodeMap;
import org.w3c.dom.Node;
import org.w3c.dom.NodeList;
import org.xml.sax.InputSource;
public final class XmlTool {
private static final Map<String, Integer> ENTITIES = new HashMap<>();
- private static final MsoLogger LOGGER = MsoLogger.getMsoLogger (MsoLogger.Catalog.BPEL, XmlTool.class);
+ private static final Logger logger = LoggerFactory.getLogger(XmlTool.class);
static {
ENTITIES.put("amp", 38);
ENTITIES.put("quot", 34);
*/
public static String removeNamespaces(Object xml) {
if (xml == null) {
- LOGGER.debug("removeNamespaces input object is null , returning null");
+ logger.debug("removeNamespaces input object is null , returning null");
return null;
}
}
return out.toString();
} catch (Exception e) {
- LOGGER.debug("Exception at readResourceFile stream: " + e);
+ logger.debug("Exception at readResourceFile stream: " + e);
return null;
}
}
//System.out.println("Did not find element tag " + elementTag + " in XML");
return Optional.empty();
} else {
- modNode.setTextContent(newValue);
+ modNode.setTextContent(newValue);
}
TransformerFactory transformerFactory = TransformerFactory.newInstance();
* ================================================================================
* Copyright (C) 2017 AT&T Intellectual Property. All rights reserved.
* ================================================================================
+ * Modifications Copyright (c) 2019 Samsung
+ * ================================================================================
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
package org.onap.so.bpmn.core.utils;
import java.sql.Connection;
-import java.sql.DriverManager;
import java.sql.PreparedStatement;
import java.sql.SQLException;
-import org.onap.so.logger.MsoLogger;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
/**
* Sets up the unit test (H2) database for Camunda.
*/
public class CamundaDBSetup {
private static boolean isDBConfigured = false;
- private static final MsoLogger LOGGER = MsoLogger.getMsoLogger(MsoLogger.Catalog.BPEL, CamundaDBSetup.class);
+ private static final Logger logger = LoggerFactory.getLogger(CamundaDBSetup.class);
private CamundaDBSetup() {
}
return;
}
- LOGGER.debug ("Configuring the Camunda H2 database for MSO");
+ logger.debug ("Configuring the Camunda H2 database for MSO");
Connection connection = null;
PreparedStatement stmt = null;
try {
stmt.close();
} catch (Exception e) {
- LOGGER.debug("Exception :",e);
+ logger.debug("Exception :",e);
}
}
try {
connection.close();
} catch (Exception e) {
- LOGGER.debug("Exception :",e);
+ logger.debug("Exception :",e);
}
}
}
}
-}
\ No newline at end of file
+}