net.sourceforge.pmd.lang.symboltable.NameOccurrence
public class JavaNameOccurrence extends java.lang.Object implements net.sourceforge.pmd.lang.symboltable.NameOccurrence
Constructor | Description |
---|---|
JavaNameOccurrence(JavaNode location,
java.lang.String image) |
Modifier and Type | Method | Description |
---|---|---|
boolean |
equals(java.lang.Object o) |
|
int |
getArgumentCount() |
|
java.lang.String |
getImage() |
|
JavaNode |
getLocation() |
|
net.sourceforge.pmd.lang.symboltable.NameOccurrence |
getNameForWhichThisIsAQualifier() |
|
int |
hashCode() |
|
boolean |
isMethodOrConstructorInvocation() |
|
boolean |
isMethodReference() |
|
boolean |
isOnLeftHandSide() |
|
boolean |
isOnRightHandSide() |
|
boolean |
isPartOfQualifiedName() |
|
boolean |
isSelfAssignment() |
Assert it the occurrence is a self assignment such as:
i += 3; |
boolean |
isThisOrSuper() |
Simply return true is the image is equal to keyword 'this' or 'super'.
|
void |
setArgumentCount(int count) |
|
void |
setIsMethodOrConstructorInvocation() |
|
void |
setNameWhichThisQualifies(net.sourceforge.pmd.lang.symboltable.NameOccurrence qualifiedName) |
|
java.lang.String |
toString() |
|
boolean |
useThisOrSuper() |
Simply return if the image start with keyword 'this' or 'super'.
|
public JavaNameOccurrence(JavaNode location, java.lang.String image)
public void setIsMethodOrConstructorInvocation()
public void setArgumentCount(int count)
public int getArgumentCount()
public boolean isMethodOrConstructorInvocation()
public boolean isMethodReference()
public void setNameWhichThisQualifies(net.sourceforge.pmd.lang.symboltable.NameOccurrence qualifiedName)
public net.sourceforge.pmd.lang.symboltable.NameOccurrence getNameForWhichThisIsAQualifier()
public boolean isPartOfQualifiedName()
public JavaNode getLocation()
getLocation
in interface net.sourceforge.pmd.lang.symboltable.NameOccurrence
public boolean isOnRightHandSide()
public boolean isOnLeftHandSide()
public boolean isSelfAssignment()
i += 3;
public boolean isThisOrSuper()
public boolean useThisOrSuper()
public boolean equals(java.lang.Object o)
equals
in class java.lang.Object
public int hashCode()
hashCode
in class java.lang.Object
public java.lang.String getImage()
getImage
in interface net.sourceforge.pmd.lang.symboltable.NameOccurrence
public java.lang.String toString()
toString
in class java.lang.Object
Copyright © 2002–2018 PMD. All rights reserved.