/** * @see org.htmlparser.Node#setParent(org.htmlparser.Node) */ public void setParent(Node arg0) { m_decorated.setParent(arg0); }
/** * @see org.htmlparser.Node#setParent(org.htmlparser.Node) */ public void setParent(Node arg0) { m_decorated.setParent(arg0); }
/** * @see org.htmlparser.Node#setParent(org.htmlparser.Node) */ public void setParent(Node arg0) { m_decorated.setParent(arg0); }
private static Tag newTag(Class<? extends Tag> klass) { Tag tag = null; try { tag = klass.newInstance(); tag.setTagName(tag.getTagName().toLowerCase()); Tag endTag = klass.newInstance(); endTag.setTagName("/" + tag.getTagName().toLowerCase()); endTag.setParent(tag); tag.setEndTag(endTag); } catch (Exception e) { LOG.log(Level.WARNING, "Unable to create tag from class " + klass, e); } return tag; }
private static Tag newTag(Class<? extends Tag> klass) { Tag tag = null; try { tag = klass.newInstance(); tag.setTagName(tag.getTagName().toLowerCase()); Tag endTag = klass.newInstance(); endTag.setTagName("/" + tag.getTagName().toLowerCase()); endTag.setParent(tag); tag.setEndTag(endTag); } catch (Exception e) { LOG.log(Level.WARNING, "Unable to create tag from class " + klass, e); } return tag; }
/** * Finish off a tag. * Perhap add a virtual end tag. * Set the end tag parent as this tag. * Perform the semantic acton. * @param tag The tag to finish off. * @param lexer A lexer positioned at the end of the tag. */ protected void finishTag (Tag tag, Lexer lexer) throws ParserException { if (null == tag.getEndTag ()) tag.setEndTag (createVirtualEndTag (tag, lexer, lexer.getPage (), lexer.getCursor ().getPosition ())); tag.getEndTag ().setParent (tag); tag.doSemanticAction (); }