-
Notifications
You must be signed in to change notification settings - Fork 85
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #413 from AvaloniaUI/add-support-for-bcl-types-in-…
…intellisense Intellisense support for BCL types
- Loading branch information
Showing
6 changed files
with
106 additions
and
42 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
23 changes: 23 additions & 0 deletions
23
...ine/Avalonia.Ide.CompletionEngine/AssemblyMetadata/AvaloniaCompilationAssemblyProvider.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
using System; | ||
using System.Collections.Generic; | ||
using System.IO; | ||
|
||
namespace Avalonia.Ide.CompletionEngine.AssemblyMetadata | ||
{ | ||
public class AvaloniaCompilationAssemblyProvider : IAssemblyProvider | ||
{ | ||
private readonly string _path; | ||
|
||
public AvaloniaCompilationAssemblyProvider(string path) | ||
{ | ||
if (string.IsNullOrEmpty(path)) | ||
throw new ArgumentNullException(nameof(path)); | ||
_path = path; | ||
} | ||
|
||
public IEnumerable<string> GetAssemblies() | ||
{ | ||
return File.ReadAllText(_path).Split(new string[] { "\r\n" }, StringSplitOptions.RemoveEmptyEntries); | ||
} | ||
} | ||
} |
9 changes: 9 additions & 0 deletions
9
CompletionEngine/Avalonia.Ide.CompletionEngine/AssemblyMetadata/IAssemblyProvider.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
using System.Collections.Generic; | ||
|
||
namespace Avalonia.Ide.CompletionEngine.AssemblyMetadata | ||
{ | ||
public interface IAssemblyProvider | ||
{ | ||
IEnumerable<string> GetAssemblies(); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters