Example usage for com.google.gwt.dev.util.collect IdentityHashSet IdentityHashSet

List of usage examples for com.google.gwt.dev.util.collect IdentityHashSet IdentityHashSet

Introduction

In this page you can find the example usage for com.google.gwt.dev.util.collect IdentityHashSet IdentityHashSet.

Prototype

public IdentityHashSet() 

Source Link

Usage

From source file:org.jboss.errai.ioc.rebind.ioc.graph.SortUnit.java

License:Apache License

/**
 * Returns the outward graph depth of this SortUnit to the outermost leaf or cycle.
 *
 * @return the outward depth of the graph from this SortUnit.
 *///from w w  w. j av a2s  .co m
public int getDepth() {
    int depth = 0;
    for (SortUnit su : getDependencies()) {
        if (su.equals(this))
            continue;

        int d = _getDepth(new IdentityHashSet<SortUnit>(), this, 1, su);
        if (d > depth) {
            depth = d;
        }
    }
    return depth;
}