private void updateLengthIfIsCollection(@NotNull final XValueChildrenList values) {
    if (myCollectionLength > 0 && values.size() == 0) return;

    final int lastIndex = values.size() - 1;

    // If there is the __len__ attribute it should always goes last.
    if (values.size() > 0 && isLen(values.getName(lastIndex))) {
      PyDebugValue len = (PyDebugValue)values.getValue(lastIndex);
      try {
        if (myCollectionLength == -1 && len.getValue() != null) {
          myCollectionLength = Integer.parseInt(len.getValue());
        }
      }
      catch (NumberFormatException ex) {
        // Do nothing.
      }
    }
  }
private void updateLengthIfIsCollection(@NotNull final XValueChildrenList values)