@Override
   public int size() {
      Iterator<E> iter = iterator();
      int count = 0;
      while (iter.hasNext()) {
         iter.next();
         count++;
      }
      return count;
   }
@ Override public int size ( ) { Iterator < E > iter = iterator ( ) ; int count = 0 ; while ( iter . hasNext ( ) ) { iter . next ( ) ; count ++ ; } return count ; }
Returns the size of the read only set.  This is done by iterating over all of the
values counting all that are in the segments.
<p>
If you are using this method to verify if the set is empty, you should instead use
the {@link ReadOnlySegmentAwareEntryCollection#isEmpty()} as it will perform better if the
size is only used for this purpose.
<p>
This time complexity for this method is always O(N).