Skip to content

Commit c0f4227

Browse files
committed
Enhance XML documentation for .NET Context Client
1 parent c88655f commit c0f4227

File tree

1 file changed

+41
-5
lines changed

1 file changed

+41
-5
lines changed

src/NetContextClient/Program.cs

Lines changed: 41 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,51 @@
1-
using ModelContextProtocol;
2-
using ModelContextProtocol.Client;
3-
using ModelContextProtocol.Protocol;
4-
using ModelContextProtocol.Protocol.Types;
5-
using ModelContextProtocol.Protocol.Transport;
1+
using ModelContextProtocol.Client;
62
using ModelContextProtocol.Configuration;
3+
using ModelContextProtocol.Protocol.Transport;
74
using NetContextClient.Models;
85
using System.CommandLine;
96
using System.Text.Json;
107

8+
/// <summary>
9+
/// Command-line interface for the .NET Context Client, which interacts with the MCP server
10+
/// to provide codebase analysis and management capabilities.
11+
///
12+
/// Built using the official C# SDK for MCP (https://github.com/modelcontextprotocol/csharp-sdk),
13+
/// this client provides commands for:
14+
/// - File system operations and project discovery
15+
/// - Code search (both text-based and semantic)
16+
/// - Package analysis
17+
/// - Ignore pattern management
18+
/// </summary>
1119
class Program
1220
{
21+
/// <summary>
22+
/// Entry point for the command-line interface. Sets up the MCP client and defines
23+
/// the command structure using System.CommandLine.
24+
/// </summary>
25+
/// <param name="args">Command-line arguments passed to the program.</param>
26+
/// <returns>
27+
/// 0 for successful execution, non-zero for errors:
28+
/// - 1: General execution error
29+
/// - Other codes as defined by System.CommandLine
30+
/// </returns>
31+
/// <remarks>
32+
/// Available commands:
33+
/// - hello: Basic connectivity test
34+
/// - set-base-dir: Set working directory
35+
/// - get-base-dir: Show current working directory
36+
/// - list-projects: Show all .NET projects
37+
/// - list-files: List files in a project
38+
/// - open-file: View file contents
39+
/// - search-code: Text-based code search
40+
/// - semantic-search: AI-powered code search
41+
/// - analyze-packages: Analyze NuGet packages
42+
/// - Ignore pattern management commands:
43+
/// * add-ignore-patterns
44+
/// * remove-ignore-patterns
45+
/// * get-ignore-patterns
46+
/// * clear-ignore-patterns
47+
/// * get-state-file-location
48+
/// </remarks>
1349
static async Task<int> Main(string[] args)
1450
{
1551
// Define client and server configuration

0 commit comments

Comments
 (0)