referenceChildren property

Map<String, CommentReferable> referenceChildren

Map of referenceName to the elements that are a member of this, but not this model element itself. Can be cached.

There is no need to duplicate references here that can be found via scope.

Implementation

@override
Map<String, CommentReferable> get referenceChildren {
  if (_referenceChildren == null) {
    _referenceChildren = {};
    if (hasParameters) {
      _referenceChildren.addEntries(parameters.explicitOnCollisionWith(this));
    }
    _referenceChildren
        .addEntries(modelType.typeArguments.explicitOnCollisionWith(this));
  }
  return _referenceChildren;
}