protected abstract Task <SignatureHelpItems> GetItemsWorkerAsync(Document document, int position, SignatureHelpTriggerInfo triggerInfo, CancellationToken cancellationToken);
protected async Task <List <Tuple <Document, IEnumerable <SignatureHelpItem> > > > GetItemsForRelatedDocuments(Document document, IEnumerable <DocumentId> relatedDocuments, int position, SignatureHelpTriggerInfo triggerInfo, CancellationToken cancellationToken) { var supportedPlatforms = new List <Tuple <Document, IEnumerable <SignatureHelpItem> > >(); foreach (var relatedDocumentId in relatedDocuments) { var relatedDocument = document.Project.Solution.GetDocument(relatedDocumentId); var semanticModel = await relatedDocument.GetSemanticModelForSpanAsync(new TextSpan(position, 0), cancellationToken).ConfigureAwait(false); var result = await GetItemsWorkerAsync(relatedDocument, position, triggerInfo, cancellationToken).ConfigureAwait(false); supportedPlatforms.Add(Tuple.Create(relatedDocument, result != null ? result.Items : SpecializedCollections.EmptyEnumerable <SignatureHelpItem>())); } return(supportedPlatforms); }