Predicate numDepends
The number of dependencies from type t
on type dep
.
Dependencies are restricted to generic and non-generic reference types.
Dependencies on parameterized or raw types are decomposed into a dependency on the corresponding generic type and separate dependencies on (source declarations of) any type arguments.
For example, a dependency on type List<Set<String>>
is represented by
dependencies on the generic types List
and Set
as well as a dependency
on the type String
but not on the parameterized types List<Set<String>>
or Set<String>
.
Import path
import semmle.code.java.DependencyCounts
predicate numDepends(RefType t, RefType dep, int value)