Java: Use hasQualifiedName rather than getQualifiedName in ExternalAPIs

It's more efficient, as it doesn't require building intermediate
strings.
This commit is contained in:
Ian Lynagh
2022-09-13 15:58:00 +01:00
parent bc7fcaa06f
commit fc445736b2

View File

@@ -24,7 +24,7 @@ private class DefaultSafeExternalApiMethod extends SafeExternalApiMethod {
or
this.getDeclaringType().hasQualifiedName("org.apache.commons.lang3", "Validate")
or
this.getQualifiedName() = "Objects.equals"
this.hasQualifiedName("java.util", "Objects", "equals")
or
this.getDeclaringType() instanceof TypeString and this.getName() = "equals"
or