@Override public void comment(final Comment comment) { String nodeValue = comment.getNodeValue(); try { TagWriterUtil.writeComment(appendable, nodeValue); } catch (IOException ioex) { throw new LagartoDOMException(ioex); } }
@Override public void comment(final CharSequence comment) { if (!enabled) { return; } if (domBuilder.config.isIgnoreWhitespacesBetweenTags()) { removeLastChildNodeIfEmptyText(parentNode, false); } if (domBuilder.config.isIgnoreComments()) { return; } Node node = new Comment(rootNode, comment.toString()); parentNode.addChild(node); }
public void condComment(CharSequence expression, boolean isStartingTag, boolean isHidden, CharSequence comment) { String defaultExpression = domBuilder.getConditionalCommentExpression(); if (defaultExpression != null) { String expressionString = expression.toString().trim(); if (expressionString.equals(defaultExpression) == false) { enabled = expressionString.equals("endif"); } } else { if (!enabled) { return; } String additionalComment = comment != null ? comment.toString() : null; Node commentNode = new Comment(expression.toString(), isStartingTag, isHidden, additionalComment); parentNode.addChild(commentNode); } }
public void comment(CharSequence comment) { if (!enabled) { return; } if (domBuilder.isIgnoreWhitespacesBetweenTags()) { removeLastChildNodeIfEmptyText(parentNode, false); } if (domBuilder.isIgnoreComments()) { return; } Node node = new Comment(comment.toString()); parentNode.addChild(node); }
@Override public void comment(final Comment comment) { String nodeValue = comment.getNodeValue(); try { TagWriterUtil.writeComment(appendable, nodeValue); } catch (IOException ioex) { throw new LagartoDOMException(ioex); } }
public void comment(CharSequence comment) { if (!enabled) { return; } if (domBuilder.config.isIgnoreWhitespacesBetweenTags()) { removeLastChildNodeIfEmptyText(parentNode, false); } if (domBuilder.config.isIgnoreComments()) { return; } Node node = new Comment(rootNode, comment.toString()); parentNode.addChild(node); }
public void comment(Comment comment) { String nodeValue = comment.getNodeValue(); try { TagWriterUtil.writeComment(appendable, nodeValue); } catch (IOException ioex) { throw new LagartoDOMException(ioex); } }
@Override public void comment(final CharSequence comment) { if (!enabled) { return; } if (domBuilder.config.isIgnoreWhitespacesBetweenTags()) { removeLastChildNodeIfEmptyText(parentNode, false); } if (domBuilder.config.isIgnoreComments()) { return; } Node node = new Comment(rootNode, comment.toString()); parentNode.addChild(node); }