static Set<RefPackage> calculateTransitiveDependenciesForPackage(
    RefPackage refPackage) {
    final Set<RefPackage> dependencies =
      refPackage.getUserData(TRANSITIVE_DEPENDENCY_PACKAGES_KEY);
    if (dependencies != null) {
      return dependencies;
    }
    final Set<RefPackage> newDependencies = new HashSet<>();
    tabulateTransitiveDependencyPackages(refPackage, newDependencies);
    refPackage.putUserData(TRANSITIVE_DEPENDENCY_PACKAGES_KEY,
                           newDependencies);
    return newDependencies;
  }
static Set<RefPackage> calculateTransitiveDependenciesForPackage(
    RefPackage refPackage)