Uses of Interface
org.codenarc.source.SourceCode
-
-
Uses of SourceCode in org.codenarc.analyzer
Fields in org.codenarc.analyzer declared as SourceCode Modifier and Type Field Description private SourceCodeSuppressionAnalyzer. sourceMethods in org.codenarc.analyzer with parameters of type SourceCode Modifier and Type Method Description protected java.util.List<Violation>AbstractSourceAnalyzer. collectViolations(SourceCode sourceCode, RuleSet ruleSet)protected booleanFilesystemSourceAnalyzer. matches(SourceCode sourceFile)Constructors in org.codenarc.analyzer with parameters of type SourceCode Constructor Description SuppressionAnalyzer(SourceCode source) -
Uses of SourceCode in org.codenarc.rule
Fields in org.codenarc.rule declared as SourceCode Modifier and Type Field Description private SourceCodeAbstractAstVisitor. sourceCodeprivate SourceCodeAbstractFieldVisitor. sourceCodeprivate SourceCodeAbstractMethodCallExpressionVisitor. sourceCodeprivate SourceCodeAbstractMethodVisitor. sourceCodeMethods in org.codenarc.rule that return SourceCode Modifier and Type Method Description SourceCodeAbstractAstVisitor. getSourceCode()protected SourceCodeAbstractFieldVisitor. getSourceCode()protected SourceCodeAbstractMethodCallExpressionVisitor. getSourceCode()protected SourceCodeAbstractMethodVisitor. getSourceCode()Methods in org.codenarc.rule with parameters of type SourceCode Modifier and Type Method Description voidAbstractAstVisitorRule. applyTo(SourceCode sourceCode, java.util.List<Violation> violations)java.util.List<Violation>AbstractRule. applyTo(SourceCode sourceCode)Apply this rule to the specified source and return a list of violations (or an empty List).abstract voidAbstractRule. applyTo(SourceCode sourceCode, java.util.List<Violation> violations)Apply this rule to the specified source and return a list of violations (or an empty List)voidAbstractSharedAstVisitorRule. applyTo(SourceCode sourceCode, java.util.List<Violation> violations)java.util.List<Violation>Rule. applyTo(SourceCode sourceCode)Apply this rule to the specified source and return a list of violations (or an empty List)voidStubRule. applyTo(SourceCode sourceCode, java.util.List<Violation> violations)protected voidAbstractSharedAstVisitorRule. applyVisitor(AstVisitor visitor, SourceCode sourceCode)protected ViolationAbstractRule. createViolation(SourceCode sourceCode, org.codehaus.groovy.ast.ASTNode node, java.lang.String message)Create a new Violation for the AST node.protected ViolationAbstractRule. createViolationForImport(SourceCode sourceCode, java.lang.String className, java.lang.String alias, java.lang.String violationMessage)Create and return a new Violation for this rule and the specified import className and aliasprotected ViolationAbstractRule. createViolationForImport(SourceCode sourceCode, org.codehaus.groovy.ast.ImportNode importNode, java.lang.String message)Create and return a new Violation for this rule and the specified importprotected AstVisitorAbstractSharedAstVisitorRule. getAstVisitor(SourceCode sourceCode)Subclasses can override to provide an AstVisitor with SourceCode or AST-specific initialization.protected abstract java.util.List<Violation>AbstractSharedAstVisitorRule. getViolations(AstVisitor astVisitor, SourceCode sourceCode)private java.util.List<Violation>AbstractSharedAstVisitorRule. removeSuppressedViolations(java.util.List<Violation> violations, SourceCode sourceCode)voidAbstractAstVisitor. setSourceCode(SourceCode sourceCode)voidAbstractFieldVisitor. setSourceCode(SourceCode sourceCode)Set the SourceCode associated with this visitorvoidAbstractMethodCallExpressionVisitor. setSourceCode(SourceCode sourceCode)Set the SourceCode associated with this visitorvoidAbstractMethodVisitor. setSourceCode(SourceCode sourceCode)Set the SourceCode associated with this visitorvoidAstVisitor. setSourceCode(SourceCode sourceCode)private booleanAbstractRule. shouldApplyThisRuleTo(SourceCode sourceCode)private voidAbstractRule. validateAstCompilerPhase(SourceCode sourceCode) -
Uses of SourceCode in org.codenarc.rule.comments
Methods in org.codenarc.rule.comments with parameters of type SourceCode Modifier and Type Method Description voidAbstractJavadocEmptyTagRule. applyTo(SourceCode sourceCode, java.util.List<Violation> violations)voidAbstractJavadocMissingDescriptionRule. applyTo(SourceCode sourceCode, java.util.List<Violation> violations)voidClassJavadocRule. applyTo(SourceCode sourceCode, java.util.List<Violation> violations)voidJavadocConsecutiveEmptyLinesRule. applyTo(SourceCode sourceCode, java.util.List<Violation> violations)voidJavadocEmptyFirstLineRule. applyTo(SourceCode sourceCode, java.util.List<Violation> violations)voidJavadocEmptyLastLineRule. applyTo(SourceCode sourceCode, java.util.List<Violation> violations)protected static booleanCommentsUtil. hasTextOnNextLine(SourceCode sourceCode, int lineNumber)protected java.lang.StringClassJavadocRule. sourceCodeNameWithoutExtension(SourceCode sourceCode) -
Uses of SourceCode in org.codenarc.rule.convention
Methods in org.codenarc.rule.convention with parameters of type SourceCode Modifier and Type Method Description voidNoTabCharacterRule. applyTo(SourceCode sourceCode, java.util.List<Violation> violations) -
Uses of SourceCode in org.codenarc.rule.design
Methods in org.codenarc.rule.design with parameters of type SourceCode Modifier and Type Method Description protected java.util.List<Violation>PrivateFieldCouldBeFinalRule. getViolations(AstVisitor visitor, SourceCode sourceCode) -
Uses of SourceCode in org.codenarc.rule.formatting
Fields in org.codenarc.rule.formatting with type parameters of type SourceCode Modifier and Type Field Description protected java.util.Map<SourceCode,java.util.Map<org.codehaus.groovy.ast.ClassNode,java.lang.Integer>>IndentationRule. classNodeIndentLevelsMethods in org.codenarc.rule.formatting with parameters of type SourceCode Modifier and Type Method Description voidBlankLineBeforePackageRule. applyTo(SourceCode sourceCode, java.util.List<Violation> violations)voidBracesForClassRule. applyTo(SourceCode sourceCode, java.util.List<Violation> violations)voidConsecutiveBlankLinesRule. applyTo(SourceCode sourceCode, java.util.List<Violation> violations)voidFileEndsWithoutNewlineRule. applyTo(SourceCode sourceCode, java.util.List<Violation> violations)voidIndentationRule. applyTo(SourceCode sourceCode, java.util.List<Violation> violations)voidLineLengthRule. applyTo(SourceCode sourceCode, java.util.List<Violation> violations)voidMissingBlankLineAfterImportsRule. applyTo(SourceCode sourceCode, java.util.List<Violation> violations)voidMissingBlankLineAfterPackageRule. applyTo(SourceCode sourceCode, java.util.List<Violation> violations)voidTrailingWhitespaceRule. applyTo(SourceCode sourceCode, java.util.List<Violation> violations) -
Uses of SourceCode in org.codenarc.rule.generic
Methods in org.codenarc.rule.generic with parameters of type SourceCode Modifier and Type Method Description voidIllegalRegexRule. applyTo(SourceCode sourceCode, java.util.List<Violation> violations)voidIllegalStringRule. applyTo(SourceCode sourceCode, java.util.List<Violation> violations)voidRequiredRegexRule. applyTo(SourceCode sourceCode, java.util.List<Violation> violations)voidRequiredStringRule. applyTo(SourceCode sourceCode, java.util.List<Violation> violations) -
Uses of SourceCode in org.codenarc.rule.imports
Methods in org.codenarc.rule.imports with parameters of type SourceCode Modifier and Type Method Description voidImportFromSunPackagesRule. addViolationForSunImport(org.codehaus.groovy.ast.ImportNode importNode, SourceCode sourceCode, java.util.List violations)voidDuplicateImportRule. applyTo(SourceCode sourceCode, java.util.List<Violation> violations)voidImportFromSamePackageRule. applyTo(SourceCode sourceCode, java.util.List<Violation> violations)voidImportFromSunPackagesRule. applyTo(SourceCode sourceCode, java.util.List<Violation> violations)voidMisorderedStaticImportsRule. applyTo(SourceCode sourceCode, java.util.List<Violation> violations)voidNoWildcardImportsRule. applyTo(SourceCode sourceCode, java.util.List<Violation> violations)voidUnnecessaryGroovyImportRule. applyTo(SourceCode sourceCode, java.util.List<Violation> violations)voidUnusedImportRule. applyTo(SourceCode sourceCode, java.util.List<Violation> violations)protected voidAbstractImportRule. eachImportLine(SourceCode sourceCode, groovy.lang.Closure closure)protected intAbstractImportRule. findLineNumberOfFirstClassDeclaration(SourceCode sourceCode) -
Uses of SourceCode in org.codenarc.rule.naming
Methods in org.codenarc.rule.naming with parameters of type SourceCode Modifier and Type Method Description voidClassNameSameAsFilenameRule. applyTo(SourceCode sourceCode, java.util.List<Violation> violations)voidPackageNameMatchesFilePathRule. applyTo(SourceCode sourceCode, java.util.List<Violation> violations) -
Uses of SourceCode in org.codenarc.rule.size
Constructors in org.codenarc.rule.size with parameters of type SourceCode Constructor Description GMetricsSourceCodeAdapter(SourceCode sourceCode) -
Uses of SourceCode in org.codenarc.rule.unnecessary
Methods in org.codenarc.rule.unnecessary with parameters of type SourceCode Modifier and Type Method Description voidUnnecessarySemicolonRule. applyTo(SourceCode sourceCode, java.util.List<Violation> violations) -
Uses of SourceCode in org.codenarc.rule.unused
Methods in org.codenarc.rule.unused with parameters of type SourceCode Modifier and Type Method Description voidUnusedVariableRule. applyTo(SourceCode sourceCode, java.util.List<Violation> violations)protected AstVisitorUnusedPrivateFieldRule. getAstVisitor(SourceCode sourceCode)protected AstVisitorUnusedPrivateMethodRule. getAstVisitor(SourceCode sourceCode)protected java.util.List<Violation>UnusedPrivateFieldRule. getViolations(AstVisitor visitor, SourceCode sourceCode)protected java.util.List<Violation>UnusedPrivateMethodRule. getViolations(AstVisitor visitor, SourceCode sourceCode) -
Uses of SourceCode in org.codenarc.source
Classes in org.codenarc.source that implement SourceCode Modifier and Type Class Description classAbstractSourceCodeclassCustomCompilerPhaseSourceDecoratorclassSourceFileclassSourceStringMethods in org.codenarc.source with parameters of type SourceCode Modifier and Type Method Description booleanSourceCodeCriteria. matches(SourceCode sourceCode)Constructors in org.codenarc.source with parameters of type SourceCode Constructor Description CustomCompilerPhaseSourceDecorator(SourceCode delegate, int compilerPhase) -
Uses of SourceCode in org.codenarc.util
Methods in org.codenarc.util with parameters of type SourceCode Modifier and Type Method Description static intAstUtil. findFirstNonAnnotationLine(org.codehaus.groovy.ast.ASTNode node, SourceCode sourceCode)gets the first non annotation line number of a node, taking into account annotations.static java.lang.StringAstUtil. getDeclaration(org.codehaus.groovy.ast.ASTNode node, SourceCode sourceCode)static java.util.ListImportUtil. getImportsSortedByLineNumber(SourceCode sourceCode)static java.lang.StringAstUtil. getLastLineOfNodeText(org.codehaus.groovy.ast.ASTNode expression, SourceCode sourceCode)static java.lang.StringAstUtil. getNodeText(org.codehaus.groovy.ast.ASTNode expression, SourceCode sourceCode)static java.util.ListImportUtil. getNonStaticImportsSortedByLineNumber(SourceCode sourceCode)static java.lang.StringAstUtil. getRawLine(SourceCode sourceCode, int lineNumber)static booleanAstUtil. isFinalVariable(org.codehaus.groovy.ast.expr.DeclarationExpression declarationExpression, SourceCode sourceCode)Return true if the DeclarationExpression represents a 'final' variable declaration.static java.util.List<java.lang.String>SourceCodeUtil. nodeSourceLines(SourceCode source, org.codehaus.groovy.ast.ASTNode node)static java.util.MapImportUtil. sourceLineAndNumberForImport(SourceCode sourceCode, java.lang.String className, java.lang.String alias)static java.util.MapImportUtil. sourceLineAndNumberForImport(SourceCode sourceCode, org.codehaus.groovy.ast.ImportNode importNode)static java.util.MapImportUtil. sourceLineAndNumberForNonStarImport(SourceCode sourceCode, org.codehaus.groovy.ast.ImportNode importNode)static java.util.MapImportUtil. sourceLineAndNumberForStarImport(SourceCode sourceCode, org.codehaus.groovy.ast.ImportNode importNode)static java.util.List<java.lang.String>SourceCodeUtil. sourceLinesBetween(SourceCode source, int startLine, int startColumn, int endLine, int endColumn)static java.util.List<java.lang.String>SourceCodeUtil. sourceLinesBetweenNodes(SourceCode source, org.codehaus.groovy.ast.ASTNode startNode, org.codehaus.groovy.ast.ASTNode endNode)
-