/
githubmirror
/
roslyn
Обзор
Документация
Войти
/
githubmirror
/
roslyn
Код
Запросы
0
Пакеты
0
Релизы
0
Аналитика
Безопасность
main
src/VisualStudio/Core/Test/Completion/TestVisualBasicSnippetInfoService.vb
32 строки
2 KB
Cyrus Najmabadi
Organize VB imports
27 июн 2025, 21:53
27 июн 2025, 21:53
e9c47fd
Код
Авторство
О чём код?
' Licensed to the .NET Foundation under one or more agreements. ' The .NET Foundation licenses this file to you under the MIT license. ' See the LICENSE file in the project root for more information. Imports System.Collections.Immutable Imports System.Composition Imports Microsoft.CodeAnalysis Imports Microsoft.CodeAnalysis.Editor.Shared.Utilities Imports Microsoft.CodeAnalysis.Host.Mef Imports Microsoft.CodeAnalysis.Shared.TestHooks Imports Microsoft.CodeAnalysis.Snippets Imports Microsoft.VisualStudio.LanguageServices.VisualBasic.Snippets Namespace Microsoft.VisualStudio.LanguageServices.UnitTests.Completion <ExportLanguageService(GetType(ISnippetInfoService), LanguageNames.VisualBasic, ServiceLayer.Test), [Shared], PartNotDiscoverable> Friend Class TestVisualBasicSnippetInfoService Inherits VisualBasicSnippetInfoService <ImportingConstructor> <Obsolete(MefConstruction.ImportingConstructorMessage, True)> Public Sub New(threadingContext As IThreadingContext, listenerProvider As IAsynchronousOperationListenerProvider) MyBase.New(threadingContext, Nothing, listenerProvider) End Sub Friend Sub SetSnippetShortcuts(newSnippetShortcuts As String()) SyncLock cacheGuard snippets = newSnippetShortcuts.Select(Function(shortcut) New SnippetInfo(shortcut, "title", "description", "path")).ToImmutableArray() snippetShortcuts = GetShortcutsHashFromSnippets(snippets) End SyncLock End Sub End Class End Namespace