001///////////////////////////////////////////////////////////////////////////////////////////////
002// checkstyle: Checks Java source code and other text files for adherence to a set of rules.
003// Copyright (C) 2001-2025 the original author or authors.
004//
005// This library is free software; you can redistribute it and/or
006// modify it under the terms of the GNU Lesser General Public
007// License as published by the Free Software Foundation; either
008// version 2.1 of the License, or (at your option) any later version.
009//
010// This library is distributed in the hope that it will be useful,
011// but WITHOUT ANY WARRANTY; without even the implied warranty of
012// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
013// Lesser General Public License for more details.
014//
015// You should have received a copy of the GNU Lesser General Public
016// License along with this library; if not, write to the Free Software
017// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
018///////////////////////////////////////////////////////////////////////////////////////////////
019
020package com.puppycrawl.tools.checkstyle.api;
021
022/**
023 * DetailNode is used to construct tree during parsing Javadoc comments.
024 * Contains array of children, parent node and other useful fields.
025 *
026 * @see com.puppycrawl.tools.checkstyle.checks.javadoc.JavadocNodeImpl
027 * @see com.puppycrawl.tools.checkstyle.checks.javadoc.AbstractJavadocCheck
028 */
029public interface DetailNode {
030
031 /**
032 * Node type.
033 *
034 * @return node type.
035 * @see JavadocTokenTypes
036 */
037 int getType();
038
039 /**
040 * Node text.
041 *
042 * @return node text
043 */
044 String getText();
045
046 /**
047 * Node line number.
048 *
049 * @return node line number
050 */
051 int getLineNumber();
052
053 /**
054 * Node column number.
055 *
056 * @return node column number.
057 */
058 int getColumnNumber();
059
060 /**
061 * Array of children.
062 *
063 * @return array of children
064 */
065 DetailNode[] getChildren();
066
067 /**
068 * Parent node.
069 *
070 * @return parent node.
071 */
072 DetailNode getParent();
073
074 /**
075 * Node index among parent's children.
076 *
077 * @return index
078 */
079 int getIndex();
080
081}