コード例 #1
0
ファイル: TexoEngineBuilder.cs プロジェクト: akobr/texo.ui
        private IntellisenseService CreateIntellisenseService()
        {
            var service = new IntellisenseService(environment, commandManagement);

            registerToMessageBus.Register <IInputTreeUpdatedMessage>(service);
            return(service);
        }
コード例 #2
0
        private async Task <IEnumerable <string> > FindCompletionsAsync(string source)
        {
            var workspace = await TestHelpers.CreateSimpleWorkspace(source);

            var controller = new IntellisenseService(workspace, new FormattingOptions());
            var request    = CreateRequest(source);
            var response   = await controller.Handle(request);

            var completions = response as IEnumerable <AutoCompleteResponse>;

            return(completions.Select(completion => BuildCompletion(completion)));
        }
コード例 #3
0
        private async Task <IEnumerable <AutoCompleteResponse> > FindCompletionsAsync(string source, AutoCompleteRequest request = null)
        {
            var workspace = await TestHelpers.CreateSimpleWorkspace(_plugInHost, source);

            var controller = new IntellisenseService(workspace, new FormattingOptions());

            if (request == null)
            {
                request = CreateRequest(source);
            }

            var response = await controller.Handle(request);

            var completions = response as IEnumerable <AutoCompleteResponse>;

            return(completions);
        }
コード例 #4
0
        private async Task<IEnumerable<AutoCompleteResponse>> FindCompletionsAsync(string source, AutoCompleteRequest request = null)
        {
            var workspace = await TestHelpers.CreateSimpleWorkspace(source);
            var controller = new IntellisenseService(workspace, new FormattingOptions());

            if (request == null)
            {
                request = CreateRequest(source);
            }

            var response = await controller.Handle(request);
            var completions = response as IEnumerable<AutoCompleteResponse>;
            return completions;
        }