root/Source/devtools/scripts/jsdoc-validator/src/org/chromium/devtools/jsdoc/ValidationCheck.java

/* [<][>][^][v][top][bottom][index][help] */

DEFINITIONS

This source file includes following definitions.
  1. getNodeText
  2. setContext

package org.chromium.devtools.jsdoc;

import com.google.javascript.rhino.head.ast.AstNode;

/**
 * A base class for all JSDoc validation checks.
 */
public abstract class ValidationCheck implements DoDidNodeVisitor {

    private ValidatorContext context;

    protected String getNodeText(AstNode node) {
        return context.getNodeText(node);
    }

    protected void setContext(ValidatorContext context) {
        if (this.context != null) {
            throw new RuntimeException("ValidatorContext already set");
        }
        this.context = context;
    }
}

/* [<][>][^][v][top][bottom][index][help] */