TouchSocket Documentation

repository·master·Indexed 22 days ago

https://github.com/rrqm/touchsocket

A high-performance .NET networking framework for building scalable communication applications supporting TCP, UDP, MQTT, WebSocket, SSL, HTTP, Modbus, and RPC. It features a flexible plugin/adapter architecture, optimized memory management via TouchSocket.Core, and specialized extensions including TouchSocket.AspNetCore for web services, TouchSocket.CoAP for Constrained Application Protocol, and TouchSocket.Dmtp for duplex binary data communication.

Tokens
118.2K
Snippets
150
Records
675
Agent score
79%

What's inside TouchSocket

  1. Overview of TouchSocket.JsonRpc

    master
    TouchSocket.JsonRpc is a component library designed to provide both JsonRpc servers and clients. It allows developers to build communication layers using Tcp, Http, and WebSocket protocols. It is designed for cross-platform compatibility, enabling seamless integration with platforms such as Web and Android.
  2. Overview of TouchSocket.XmlRpc

    master
    TouchSocket.XmlRpc is a component library designed to provide both XmlRpc server and client capabilities. It allows developers to create XmlRpc service parsers that fully support XmlRpc data types, including complex nested types and arrays. It is specifically designed to work seamlessly with CookComputing.XmlRpcV2, enabling integration across various platforms without the restrictions typically found in Web or Android environments.
  3. Overview of TouchSocket.NamedPipe

    master
    TouchSocket.NamedPipe is a component library based on Named Pipes. It encapsulates Named Pipe servers and clients, along with connection and disconnection messages, to mimic the experience of using TCP. This allows developers to use Named Pipes with an API surface that is extremely close to standard TCP implementations, reducing the learning curve.
  4. Overview of TouchSocket.WebApi.Swagger

    master
    TouchSocket.WebApi.Swagger is a Swagger UI component library specifically designed for TouchSocket.WebApi. It provides a visual interface in the browser to debug and test WebApi endpoints directly, improving development and testing efficiency. The library embeds all necessary static resources (HTML, CSS, JavaScript) into your project to simplify deployment.
  5. Overview of TouchSocket.Semi

    master

    TouchSocket.Semi is a semiconductor protocol library designed for communication between semiconductor equipment and hosts. It provides implementations for:

    • HSMS (SEMI E37): A TCP-based transport layer.
    • SECS-II (SEMI E5): Data item parsing and serialization.

    It is intended for developers building semiconductor automation and communication software.

  6. Overview of TouchSocket.Core features

    master

    TouchSocket.Core is a foundational service library designed to provide high-performance utility components for .NET applications. It focuses on resource management, data processing, and system utilities to reduce overhead and improve efficiency.

    Key functional areas include:

    Memory & Object Management

    • Memory Pool: Efficiently manages memory resources to reduce allocation and reclamation overhead.
    • Object Pool: Reuses object instances to avoid the performance cost of frequent creation and destruction.

    Data Processing

    • Streaming Data Unpacker: Efficiently unpacks streaming data for easier parsing and processing.
    • High-Performance Binary Serializer: Provides fast binary serialization and deserialization.

    Logic & Communication

    • Waiting Logic Pool: Manages waiting logic to improve asynchronous operation efficiency.
    • AppMessenger: An in-app messaging mechanism for facilitating communication between different modules.

    File & Storage

    • File Pool: Optimizes file resource usage.
    • File Quick Operations: Provides convenient methods for reading, writing, copying, and moving files.
    • XML Fast Storage: Enables rapid storage and retrieval of XML data.

    Security & Monitoring

    • 3DES Encryption: Provides 3DES encryption algorithms for data security.
    • Runtime Measurement: Tools to measure code execution time for performance optimization.
    • Standardized Logging Interface: A unified interface for managing application logs.
  7. Overview of TouchSocket.Mqtt

    master
    TouchSocket.Mqtt is a component library designed to provide both MQTT server and client capabilities. It allows developers to create MQTT servers and clients based on TCP and WebSocket protocols. It is designed for full MQTT feature support and seamless integration with various platforms, including Web and Android.
  8. Overview of ThingsGateway

    master
    ThingsGateway is a cross-platform edge collection gateway built on NetCore designed for industrial device data acquisition. It provides a framework for collecting data from various industrial protocols and includes components for device driver development and administrative management.
  9. Overview of TouchSocket.Rpc

    master
    TouchSocket.Rpc is an ultra-lightweight, high-performance, and extensible RPC management platform framework. It is designed to allow developers to quickly implement RPC execution functionality. The framework is highly extensible, allowing for the addition of new RPC types and features as needed.
  10. Overview of TouchSocket.WebApi

    master

    TouchSocket.WebApi is a component library designed to provide both WebApi server and client capabilities. It enables developers to create WebApi service parsers and clients to facilitate cross-language RPC (Remote Procedure Call) function calls across desktop, web, and mobile platforms.

    Key features include:

    • Cross-platform calling: Supports RPC function calls across desktop, web, and mobile environments.
    • Parameter passing: Supports both Get and Post methods for passing parameters.
    • Custom routing: Allows developers to define and customize WebApi routes.
  11. Overview of TouchSocket.Rpc.RateLimiting

    master

    TouchSocket.Rpc.RateLimiting is an extension package for the TouchSocket RPC management platform. It provides rate-limiting capabilities for RPC calls, allowing developers to control the frequency of RPC requests to prevent system overload and performance degradation during high concurrency.

    It is compatible with all RPC types supported by the platform, including:

    • DmtpRpc
    • XmlRpc
    • JsonRpc
    • WebApi