资源简介

SuperSocket 是一个轻量级的可扩展的 Socket 开发框架,
可用来构建一个服务器端 Socket 程序,而无需了解如何使用 Socket,
如何维护Socket连接,Socket是如何工作的。该项目使用纯 C# 开发,
易于扩展和集成到已有的项目。只要你的已有系统是使用.NET开发的,
你都能够使用 SuperSocket来轻易的开发出你需要的Socket应用程序来集成到你的现有系统之中。

资源截图

代码片段和文件信息

using System.Linq;
using System.Text;
using System.Threading.Tasks;
using SuperSocket;
using SuperSocket.Command;
using SuperSocket.Protobase;

namespace CommandServer
{
    public class ADD : IAsyncCommand
    {
        public string Key => “ADD“;

        public string Name => Key;

        public async Task ExecuteAsync(IAppSession session StringPackageInfo package)
        {
            var result = package.Parameters
                .Select(p => int.Parse(p))
                .Sum();

            await session.SendAsync(Encoding.UTF8.GetBytes(result.ToString() + “\r\n“));
        }
    }
}

 属性            大小     日期    时间   名称
----------- ---------  ---------- -----  ----
     目录           0  2019-10-22 07:13  SuperSocket-master\
     文件          81  2019-10-22 07:13  SuperSocket-master\.gitignore
     文件         195  2019-10-22 07:13  SuperSocket-master\.travis.yml
     目录           0  2019-10-22 07:13  SuperSocket-master\.vscode\
     文件        1215  2019-10-22 07:13  SuperSocket-master\.vscode\launch.json
     文件         506  2019-10-22 07:13  SuperSocket-master\.vscode\tasks.json
     文件         255  2019-10-22 07:13  SuperSocket-master\Dependencies.props
     文件         391  2019-10-22 07:13  SuperSocket-master\Directory.Build.props
     文件       11323  2019-10-22 07:13  SuperSocket-master\LICENSE
     文件        2050  2019-10-22 07:13  SuperSocket-master\README.md
     文件        2731  2019-10-22 07:13  SuperSocket-master\SuperSocket.nuspec
     文件       15597  2019-10-22 07:13  SuperSocket-master\SuperSocket.sln
     目录           0  2019-10-22 07:13  SuperSocket-master\samples\
     目录           0  2019-10-22 07:13  SuperSocket-master\samples\CommandServer\
     文件         629  2019-10-22 07:13  SuperSocket-master\samples\CommandServer\ADD.cs
     文件         510  2019-10-22 07:13  SuperSocket-master\samples\CommandServer\CommandServer.csproj
     文件         652  2019-10-22 07:13  SuperSocket-master\samples\CommandServer\MULT.cs
     文件        1778  2019-10-22 07:13  SuperSocket-master\samples\CommandServer\Program.cs
     文件         650  2019-10-22 07:13  SuperSocket-master\samples\CommandServer\SUB.cs
     目录           0  2019-10-22 07:13  SuperSocket-master\samples\EchoServer\
     文件         419  2019-10-22 07:13  SuperSocket-master\samples\EchoServer\EchoServer.csproj
     文件        1324  2019-10-22 07:13  SuperSocket-master\samples\EchoServer\Program.cs
     目录           0  2019-10-22 07:13  SuperSocket-master\src\
     目录           0  2019-10-22 07:13  SuperSocket-master\src\SuperSocket.Channel\
     文件         648  2019-10-22 07:13  SuperSocket-master\src\SuperSocket.Channel\Channelbase.cs
     文件         532  2019-10-22 07:13  SuperSocket-master\src\SuperSocket.Channel\ChannelOptions.cs
     文件         485  2019-10-22 07:13  SuperSocket-master\src\SuperSocket.Channel\IChannel.cs
     文件         247  2019-10-22 07:13  SuperSocket-master\src\SuperSocket.Channel\IPipeChannel.cs
     文件        1988  2019-10-22 07:13  SuperSocket-master\src\SuperSocket.Channel\PipeChannel.PackageTask.cs
     文件        8828  2019-10-22 07:13  SuperSocket-master\src\SuperSocket.Channel\PipeChannel.cs
     文件        1301  2019-10-22 07:13  SuperSocket-master\src\SuperSocket.Channel\RelayPipeChannel.cs
............此处省略116个文件信息

评论

共有 条评论