class UrlHelper {

    public static String getBaseUrl(Document document) {
        Node baseNode = XPathHelper.getXhtmlNode(document, "//head/base/@href");
        return baseNode != null ? baseNode.getTextContent() : null;
    }

    private  UrlHelper();

}