Uses of Class
com.puppycrawl.tools.checkstyle.checks.coding.RequireThisCheck.AbstractFrame
-
Packages that use RequireThisCheck.AbstractFrame Package Description com.puppycrawl.tools.checkstyle.checks.coding Contains the Coding checks that are bundled with the main distribution. -
-
Uses of RequireThisCheck.AbstractFrame in com.puppycrawl.tools.checkstyle.checks.coding
Subclasses of RequireThisCheck.AbstractFrame in com.puppycrawl.tools.checkstyle.checks.coding Modifier and Type Class Description private static class
RequireThisCheck.AnonymousClassFrame
An anonymous class frame; holds instance variable names.private static class
RequireThisCheck.BlockFrame
A frame initiated on entering a statement list; holds local variable names.private static class
RequireThisCheck.CatchFrame
A frame initiated on entering a catch block; holds local catch variable names.private static class
RequireThisCheck.ClassFrame
A frame initiated at class, enum or interface definition; holds instance variable names.private static class
RequireThisCheck.ConstructorFrame
A frame initiated at constructor definition.private static class
RequireThisCheck.ForFrame
A frame initiated on entering a for block; holds local for variable names.private static class
RequireThisCheck.MethodFrame
A frame initiated at method definition; holds a method definition token.private static class
RequireThisCheck.TryWithResourcesFrame
A frame initiated on entering a try-with-resources construct; holds local resources for the try block.Fields in com.puppycrawl.tools.checkstyle.checks.coding declared as RequireThisCheck.AbstractFrame Modifier and Type Field Description private RequireThisCheck.AbstractFrame
RequireThisCheck.AbstractFrame. parent
Parent frame.Fields in com.puppycrawl.tools.checkstyle.checks.coding with type parameters of type RequireThisCheck.AbstractFrame Modifier and Type Field Description private Deque<RequireThisCheck.AbstractFrame>
RequireThisCheck. current
Frame for the currently processed AST.private Map<DetailAST,RequireThisCheck.AbstractFrame>
RequireThisCheck. frames
Tree of all the parsed frames.Methods in com.puppycrawl.tools.checkstyle.checks.coding that return RequireThisCheck.AbstractFrame Modifier and Type Method Description private RequireThisCheck.AbstractFrame
RequireThisCheck. findClassFrame(DetailAST name, boolean lookForMethod)
Find the class frame containing declaration.private RequireThisCheck.AbstractFrame
RequireThisCheck. findFrame(DetailAST name, boolean lookForMethod)
Find frame containing declaration.private static RequireThisCheck.AbstractFrame
RequireThisCheck. findFrame(RequireThisCheck.AbstractFrame frame, DetailAST name, boolean lookForMethod)
Find frame containing declaration.private RequireThisCheck.AbstractFrame
RequireThisCheck. getClassFrameWhereViolationIsFound(DetailAST ast)
Returns the class frame where violation is found (where the field is used without 'this') or null otherwise.private RequireThisCheck.AbstractFrame
RequireThisCheck. getFieldWithoutThis(DetailAST ast, int parentType)
Returns the frame where the field is declared, if the given field is used without 'this', and null otherwise.protected RequireThisCheck.AbstractFrame
RequireThisCheck.AbstractFrame. getIfContains(DetailAST identToFind, boolean lookForMethod)
Check whether the frame contains a given name.protected RequireThisCheck.AbstractFrame
RequireThisCheck.CatchFrame. getIfContains(DetailAST identToFind, boolean lookForMethod)
protected RequireThisCheck.AbstractFrame
RequireThisCheck.ClassFrame. getIfContains(DetailAST identToFind, boolean lookForMethod)
private RequireThisCheck.AbstractFrame
RequireThisCheck. getMethodWithoutThis(DetailAST ast)
Returns the frame where the method is declared, if the given method is used without 'this' and null otherwise.protected RequireThisCheck.AbstractFrame
RequireThisCheck.AbstractFrame. getParent()
Returns the parent frame.Methods in com.puppycrawl.tools.checkstyle.checks.coding with parameters of type RequireThisCheck.AbstractFrame Modifier and Type Method Description private static void
RequireThisCheck. collectMethodDeclarations(Deque<RequireThisCheck.AbstractFrame> frameStack, DetailAST ast, RequireThisCheck.AbstractFrame frame)
CollectsMETHOD_DEF
declarations.private static void
RequireThisCheck. collectVariableDeclarations(DetailAST ast, RequireThisCheck.AbstractFrame frame)
Collects variable declarations.private static RequireThisCheck.AbstractFrame
RequireThisCheck. findFrame(RequireThisCheck.AbstractFrame frame, DetailAST name, boolean lookForMethod)
Find frame containing declaration.private static boolean
RequireThisCheck. isInsideConstructorFrame(RequireThisCheck.AbstractFrame frame)
Checks whether a field usage frame is inside constructor frame.private static boolean
RequireThisCheck. isReturnedVariable(RequireThisCheck.AbstractFrame currentFrame, DetailAST ident)
Checks whether the current variable is returned from the method.private static boolean
RequireThisCheck. isUserDefinedArrangementOfThis(RequireThisCheck.AbstractFrame currentFrame, DetailAST ident)
Checks whether user arranges 'this' for variable in method, constructor, or block on his own.private void
RequireThisCheck. logViolation(String msgKey, DetailAST ast, RequireThisCheck.AbstractFrame frame)
Helper method to log a Violation.Method parameters in com.puppycrawl.tools.checkstyle.checks.coding with type arguments of type RequireThisCheck.AbstractFrame Modifier and Type Method Description private static void
RequireThisCheck. collectDeclarations(Deque<RequireThisCheck.AbstractFrame> frameStack, DetailAST ast)
Parses the next AST for declarations.private static void
RequireThisCheck. collectMethodDeclarations(Deque<RequireThisCheck.AbstractFrame> frameStack, DetailAST ast, RequireThisCheck.AbstractFrame frame)
CollectsMETHOD_DEF
declarations.private void
RequireThisCheck. endCollectingDeclarations(Queue<RequireThisCheck.AbstractFrame> frameStack, DetailAST ast)
Ends parsing of the AST for declarations.
-