1 | /** |
2 | * BSD-style license; for more info see http://xradar.sourceforge.net/license.html |
3 | */ |
4 | package org.sourceforge.xradar.util; |
5 | |
6 | import javax.xml.parsers.DocumentBuilder; |
7 | import javax.xml.parsers.ParserConfigurationException; |
8 | |
9 | import org.sourceforge.xradar.XRadarException; |
10 | |
11 | import com.sun.org.apache.xerces.internal.jaxp.DocumentBuilderFactoryImpl; |
12 | |
13 | /** |
14 | * @author Romain PELISSE <belaran@gmail.com> |
15 | * |
16 | */ |
17 | public class XMLUtils { |
18 | |
19 | public static DocumentBuilder getDocumentBuilder() throws XRadarException { |
20 | try { |
21 | return new DocumentBuilderFactoryImpl().newDocumentBuilder(); |
22 | } catch (ParserConfigurationException e) { |
23 | throw new XRadarException(e); |
24 | } |
25 | } |
26 | |
27 | } |