@ProviderFor(value=JavacAnnotationHandler.class) public class HandleEqualsAndHashCode extends JavacAnnotationHandler<EqualsAndHashCode>
lombok.EqualsAndHashCode
annotation for javac.trees
Constructor and Description |
---|
HandleEqualsAndHashCode() |
Modifier and Type | Method and Description |
---|---|
void |
checkForBogusFieldNames(JavacNode type,
AnnotationValues<EqualsAndHashCode> annotation) |
JCMethodDecl |
createCanEqual(JavacNode typeNode,
JCTree source,
<any> onParam) |
JCMethodDecl |
createEquals(JavacNode typeNode,
<any> fields,
boolean callSuper,
JavacHandlerUtil.FieldAccess fieldAccess,
boolean needsCanEqual,
JCTree source,
<any> onParam) |
JCMethodDecl |
createHashCode(JavacNode typeNode,
<any> fields,
boolean callSuper,
JavacHandlerUtil.FieldAccess fieldAccess,
JCTree source) |
JCExpressionStatement |
createResultCalculation(JavacNode typeNode,
JCExpression expr) |
JCExpression |
createTypeReference(JavacNode type,
boolean addWildcards) |
JCStatement |
generateCompareFloatOrDouble(JCExpression thisDotField,
JCExpression otherDotField,
lombok.javac.JavacTreeMaker maker,
JavacNode node,
boolean isDouble) |
void |
generateEqualsAndHashCodeForType(JavacNode typeNode,
JavacNode source) |
void |
generateMethods(JavacNode typeNode,
JavacNode source,
<any> excludes,
<any> includes,
java.lang.Boolean callSuper,
boolean whineIfExists,
JavacHandlerUtil.FieldAccess fieldAccess,
<any> onParam) |
void |
handle(AnnotationValues<EqualsAndHashCode> annotation,
JCAnnotation ast,
JavacNode annotationNode)
Called when an annotation is found that is likely to match the annotation you're interested in.
|
JCExpression |
longToIntForHashCode(lombok.javac.JavacTreeMaker maker,
JCExpression ref1,
JCExpression ref2)
The 2 references must be clones of each other.
|
JCStatement |
returnBool(lombok.javac.JavacTreeMaker maker,
boolean bool) |
getAnnotationHandledByThisHandler, setTrees
public void checkForBogusFieldNames(JavacNode type, AnnotationValues<EqualsAndHashCode> annotation)
public void handle(AnnotationValues<EqualsAndHashCode> annotation, JCAnnotation ast, JavacNode annotationNode)
JavacAnnotationHandler
handle
in class JavacAnnotationHandler<EqualsAndHashCode>
annotation
- The actual annotation - use this object to retrieve the annotation parameters.ast
- The javac AST node representing the annotation.annotationNode
- The Lombok AST wrapper around the 'ast' parameter. You can use this object
to travel back up the chain (something javac AST can't do) to the parent of the annotation, as well
as access useful methods such as generating warnings or errors focused on the annotation.public void generateEqualsAndHashCodeForType(JavacNode typeNode, JavacNode source)
public void generateMethods(JavacNode typeNode, JavacNode source, <any> excludes, <any> includes, java.lang.Boolean callSuper, boolean whineIfExists, JavacHandlerUtil.FieldAccess fieldAccess, <any> onParam)
public JCMethodDecl createHashCode(JavacNode typeNode, <any> fields, boolean callSuper, JavacHandlerUtil.FieldAccess fieldAccess, JCTree source)
public JCExpressionStatement createResultCalculation(JavacNode typeNode, JCExpression expr)
public JCExpression longToIntForHashCode(lombok.javac.JavacTreeMaker maker, JCExpression ref1, JCExpression ref2)
public JCExpression createTypeReference(JavacNode type, boolean addWildcards)
public JCMethodDecl createEquals(JavacNode typeNode, <any> fields, boolean callSuper, JavacHandlerUtil.FieldAccess fieldAccess, boolean needsCanEqual, JCTree source, <any> onParam)
public JCMethodDecl createCanEqual(JavacNode typeNode, JCTree source, <any> onParam)
public JCStatement generateCompareFloatOrDouble(JCExpression thisDotField, JCExpression otherDotField, lombok.javac.JavacTreeMaker maker, JavacNode node, boolean isDouble)
public JCStatement returnBool(lombok.javac.JavacTreeMaker maker, boolean bool)
Copyright © 2009-2015 The Project Lombok Authors, licensed under the MIT licence.