File:  [Public] / java / classes / org / w3c / tools / markup / DOMMethod.java
Revision 1.1: download - view: text, annotated - select for diffs
Fri Apr 2 13:11:24 1999 UTC (26 years, 8 months ago) by plehegar
Branches: MAIN
CVS tags: rel-2-2, HEAD
Freeze

/*
 * Copyright (c) 1999 World Wide Web Consortium
 * (Massachusetts Institute of Technology, Institut National de Recherche
 *  en Informatique et en Automatique, Keio University).
 * All Rights Reserved. http://www.w3.org/Consortium/Legal/
 *
 * $Id: DOMMethod.java,v 1.1 1999/04/02 13:11:24 plehegar Exp $
 */
package org.w3c.tools.markup;

import org.w3c.dom.Node;

/**
 * @version $Revision: 1.1 $
 * @author  Philippe Le Hegaret
 */
public class DOMMethod {

    public static Node getParentNode(Node node) {
	Node parent = node.getParentNode();

	while ((parent != null)
	       && (parent.getNodeType() == Node.ENTITY_REFERENCE_NODE)) {
	    parent = node.getParentNode();
	}
	return parent;
    }
}

Webmaster