visitReference

fun visitReference(    reference: ResolverReference,     visitResources: Boolean,     withReference: (ResolverReference) -> Unit): Int

Visit the provided ResolverReference by handing it to the provided lambda then add all its children to a stack. Then pop the next ResolverReference and iteratively visit it until the stack has been emptied.

NOTE Graph uses depth-first traversal to visit each reference.

Return

The number of entries that were processed.

Parameters

reference

The ResolverReference being visited.

visitResources

true indicates resources should be included in the walk; false indicates walk should be restricted to packages and modules.

withReference

The lambda that accepts the visited ResolverReference. This ResolverReference will not be provided to the lambda.