android/guava/src/com/google/common/graph/NetworkBuilder.java
public NetworkBuilder<N, E> expectedEdgeCount(int expectedEdgeCount) {
    this.expectedEdgeCount = Optional.of(checkNonNegative(expectedEdgeCount));
    return this;
  }
public NetworkBuilder<N, E> expectedEdgeCount(int expectedEdgeCount) {
    this.expectedEdgeCount = Optional.of(checkNonNegative(expectedEdgeCount));
    return this;
  }
Specifies the expected number of edges in the network.

@throws IllegalArgumentException if {@code expectedEdgeCount} is negative