wanshenmean
2026-03-26 8e42d0c1b7ae36cff2e7c69999117911a4b6f300
分支
用户 wanshenmean <cathay_xy@163.com>
星期四, 三月 26, 2026 17:31 +0800
提交者 wanshenmean <cathay_xy@163.com>
星期四, 三月 26, 2026 17:31 +0800
提交8e42d0c1b7ae36cff2e7c69999117911a4b6f300
目录 dd3785002ab370f7999d0872403afce66447874c 目录 | zip | gz
上一版本 0831fc62745a46b056e450395b0366ec168a6e55 查看 | 对比
feat(WCS): 完善 WIDESEAWCS_Tasks 模块代码注释

为以下四个模块的 39 个文件添加完整的 XML 文档注释,提升代码可维护性和团队协作效率。

## RobotJob 机械手任务模块(13 个文件)
- RobotJob.cs: Quartz IJob 入口,使用 [DisallowConcurrentExecution] 禁止并发执行
- RobotClientManager.cs: TCP 客户端连接管理,支持订阅和断开事件
- RobotStateManager.cs: 线程安全的机械手状态管理,基于版本号的乐观锁
- RobotSocketState.cs: Redis 中存储的机械手状态数据模型
- RobotTaskProcessor.cs: 任务获取、派发、WMS API 调用
- RobotMessageHandler.cs: TCP 消息路由入口
- RobotBarcodeGenerator.cs: 托盘条码生成器
- Abstractions/: 5 个接口(IRobotMessageRouter, IRobotWorkflowOrchestrator, ISocketClientGateway, IRobotPrefixCommandHandler, IRobotSimpleCommandHandler)
- Workflow/: 状态机和工作流处理器(RobotWorkflowOrchestrator, RobotSimpleCommandHandler, RobotPrefixCommandHandler)

## ConveyorLineNewJob 输送线任务模块(9 个文件)
- CommonConveyorLineNewJob.cs: 核心执行逻辑,使用 Parallel.For 并行处理子设备
- ConveyorLineDispatchHandler.cs: 入库/出库任务调度处理
- ConveyorLineTaskFilter.cs: 任务查询和 WMS 请求门面类
- ConveyorLineTargetAddressSelector.cs: 上下层请求目标地址选择
- ConveyorLine/ConveyorLineDBNameNew.cs: PLC 寄存器名称枚举
- ConveyorLine/ConveyorLineTaskCommandNew.cs: 输送线 PLC 命令数据类
- ConveyorLine/CheckPalletPosition.cs: 托盘位置检查配置
- PinMachine/: 插拔钉机 PLC 寄存器名称和命令类
- ConstraintMachine/: 拘束机 PLC 寄存器名称和命令类

## StackerCraneJob 堆垛机任务模块(6 个文件)
- CommonStackerCraneJob.cs: 核心执行逻辑,协调选择器、构建器和命令发送
- StackerCraneTaskSelector.cs: 任务选择策略(入库优先/出库优先,移库检查,站台可用性判断)
- StackerCraneCommandBuilder.cs: 命令构建器,支持入库/出库/移库
- StackerCraneCommandConfig.cs: 命令类型配置
- StackerCraneDBName.cs: PLC 寄存器名称枚举
- StackerCraneTaskCommand.cs: 堆垛机任务命令数据类

## SocketServer TCP 套接字服务器模块(9 个文件)
- TcpSocketServer.cs: 核心类,客户端字典、锁、设备绑定
- TcpSocketServer.Server.cs: StartAsync/StopAsync/AcceptLoopAsync/MonitorClientsAsync
- TcpSocketServer.Clients.cs: 客户端管理和广播消息
- TcpSocketServer.Messaging.cs: 消息接收循环,帧解析,编码自动检测
- TcpSocketServer.Dispose.cs: 资源释放
- SocketServerHostedService.cs: ASP.NET Core IHostedService 包装
- SocketServerOptions.cs: 配置选项(端口、编码、心跳、空闲超时、消息帧)
- SocketClientGateway.cs: ISocketClientGateway 接口实现

## Bug 修复
- CommonStackerCraneJob.cs: 修复事件处理器中的类型转换错误(CommonConveyorLine → IStackerCrane)
- 修复 RobotJob/Abstractions 接口文件的中文编码问题(UTF-8)

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
已修改39个文件
3594 ■■■■ 文件已修改
Code/WCS/WIDESEAWCS_Server/WIDESEAWCS_Tasks/ConveyorLineNewJob/CommonConveyorLineNewJob.cs 170 ●●●● 对比 | 查看 | 原始文档 | blame | 历史
Code/WCS/WIDESEAWCS_Server/WIDESEAWCS_Tasks/ConveyorLineNewJob/ConstraintMachine/ConstraintMachineDBName.cs 44 ●●●● 对比 | 查看 | 原始文档 | blame | 历史
Code/WCS/WIDESEAWCS_Server/WIDESEAWCS_Tasks/ConveyorLineNewJob/ConveyorLine/CheckPalletPosition.cs 23 ●●●●● 对比 | 查看 | 原始文档 | blame | 历史
Code/WCS/WIDESEAWCS_Server/WIDESEAWCS_Tasks/ConveyorLineNewJob/ConveyorLine/ConveyorLineDBNameNew.cs 145 ●●●● 对比 | 查看 | 原始文档 | blame | 历史
Code/WCS/WIDESEAWCS_Server/WIDESEAWCS_Tasks/ConveyorLineNewJob/ConveyorLine/ConveyorLineTaskCommandNew.cs 126 ●●●● 对比 | 查看 | 原始文档 | blame | 历史
Code/WCS/WIDESEAWCS_Server/WIDESEAWCS_Tasks/ConveyorLineNewJob/ConveyorLineDispatchHandler.cs 178 ●●●● 对比 | 查看 | 原始文档 | blame | 历史
Code/WCS/WIDESEAWCS_Server/WIDESEAWCS_Tasks/ConveyorLineNewJob/ConveyorLineTargetAddressSelector.cs 108 ●●●●● 对比 | 查看 | 原始文档 | blame | 历史
Code/WCS/WIDESEAWCS_Server/WIDESEAWCS_Tasks/ConveyorLineNewJob/ConveyorLineTaskFilter.cs 53 ●●●●● 对比 | 查看 | 原始文档 | blame | 历史
Code/WCS/WIDESEAWCS_Server/WIDESEAWCS_Tasks/ConveyorLineNewJob/PinMachine/PinMachineCommand.cs 42 ●●●● 对比 | 查看 | 原始文档 | blame | 历史
Code/WCS/WIDESEAWCS_Server/WIDESEAWCS_Tasks/ConveyorLineNewJob/PinMachine/PinMachineDBName.cs 42 ●●●●● 对比 | 查看 | 原始文档 | blame | 历史
Code/WCS/WIDESEAWCS_Server/WIDESEAWCS_Tasks/RobotJob/Abstractions/IRobotMessageRouter.cs 11 ●●●● 对比 | 查看 | 原始文档 | blame | 历史
Code/WCS/WIDESEAWCS_Server/WIDESEAWCS_Tasks/RobotJob/Abstractions/IRobotPrefixCommandHandler.cs 19 ●●●● 对比 | 查看 | 原始文档 | blame | 历史
Code/WCS/WIDESEAWCS_Server/WIDESEAWCS_Tasks/RobotJob/Abstractions/IRobotSimpleCommandHandler.cs 14 ●●●● 对比 | 查看 | 原始文档 | blame | 历史
Code/WCS/WIDESEAWCS_Server/WIDESEAWCS_Tasks/RobotJob/Abstractions/IRobotWorkflowOrchestrator.cs 9 ●●●● 对比 | 查看 | 原始文档 | blame | 历史
Code/WCS/WIDESEAWCS_Server/WIDESEAWCS_Tasks/RobotJob/Abstractions/ISocketClientGateway.cs 38 ●●●●● 对比 | 查看 | 原始文档 | blame | 历史
Code/WCS/WIDESEAWCS_Server/WIDESEAWCS_Tasks/RobotJob/RobotBarcodeGenerator.cs 20 ●●●● 对比 | 查看 | 原始文档 | blame | 历史
Code/WCS/WIDESEAWCS_Server/WIDESEAWCS_Tasks/RobotJob/RobotClientManager.cs 137 ●●●● 对比 | 查看 | 原始文档 | blame | 历史
Code/WCS/WIDESEAWCS_Server/WIDESEAWCS_Tasks/RobotJob/RobotJob.cs 160 ●●●●● 对比 | 查看 | 原始文档 | blame | 历史
Code/WCS/WIDESEAWCS_Server/WIDESEAWCS_Tasks/RobotJob/RobotMessageHandler.cs 103 ●●●●● 对比 | 查看 | 原始文档 | blame | 历史
Code/WCS/WIDESEAWCS_Server/WIDESEAWCS_Tasks/RobotJob/RobotSocketState.cs 108 ●●●● 对比 | 查看 | 原始文档 | blame | 历史
Code/WCS/WIDESEAWCS_Server/WIDESEAWCS_Tasks/RobotJob/RobotStateManager.cs 102 ●●●● 对比 | 查看 | 原始文档 | blame | 历史
Code/WCS/WIDESEAWCS_Server/WIDESEAWCS_Tasks/RobotJob/RobotTaskProcessor.cs 225 ●●●● 对比 | 查看 | 原始文档 | blame | 历史
Code/WCS/WIDESEAWCS_Server/WIDESEAWCS_Tasks/RobotJob/Workflow/RobotPrefixCommandHandler.cs 160 ●●●●● 对比 | 查看 | 原始文档 | blame | 历史
Code/WCS/WIDESEAWCS_Server/WIDESEAWCS_Tasks/RobotJob/Workflow/RobotSimpleCommandHandler.cs 108 ●●●●● 对比 | 查看 | 原始文档 | blame | 历史
Code/WCS/WIDESEAWCS_Server/WIDESEAWCS_Tasks/RobotJob/Workflow/RobotWorkflowOrchestrator.cs 148 ●●●●● 对比 | 查看 | 原始文档 | blame | 历史
Code/WCS/WIDESEAWCS_Server/WIDESEAWCS_Tasks/SocketServer/SocketClientGateway.cs 37 ●●●●● 对比 | 查看 | 原始文档 | blame | 历史
Code/WCS/WIDESEAWCS_Server/WIDESEAWCS_Tasks/SocketServer/SocketServerHostedService.cs 33 ●●●●● 对比 | 查看 | 原始文档 | blame | 历史
Code/WCS/WIDESEAWCS_Server/WIDESEAWCS_Tasks/SocketServer/SocketServerOptions.cs 67 ●●●● 对比 | 查看 | 原始文档 | blame | 历史
Code/WCS/WIDESEAWCS_Server/WIDESEAWCS_Tasks/SocketServer/TcpSocketServer.Clients.cs 77 ●●●●● 对比 | 查看 | 原始文档 | blame | 历史
Code/WCS/WIDESEAWCS_Server/WIDESEAWCS_Tasks/SocketServer/TcpSocketServer.Dispose.cs 17 ●●●● 对比 | 查看 | 原始文档 | blame | 历史
Code/WCS/WIDESEAWCS_Server/WIDESEAWCS_Tasks/SocketServer/TcpSocketServer.Messaging.cs 139 ●●●●● 对比 | 查看 | 原始文档 | blame | 历史
Code/WCS/WIDESEAWCS_Server/WIDESEAWCS_Tasks/SocketServer/TcpSocketServer.Server.cs 133 ●●●●● 对比 | 查看 | 原始文档 | blame | 历史
Code/WCS/WIDESEAWCS_Server/WIDESEAWCS_Tasks/SocketServer/TcpSocketServer.cs 146 ●●●● 对比 | 查看 | 原始文档 | blame | 历史
Code/WCS/WIDESEAWCS_Server/WIDESEAWCS_Tasks/StackerCraneJob/CommonStackerCraneJob.cs 149 ●●●●● 对比 | 查看 | 原始文档 | blame | 历史
Code/WCS/WIDESEAWCS_Server/WIDESEAWCS_Tasks/StackerCraneJob/StackerCraneCommandBuilder.cs 191 ●●●●● 对比 | 查看 | 原始文档 | blame | 历史
Code/WCS/WIDESEAWCS_Server/WIDESEAWCS_Tasks/StackerCraneJob/StackerCraneCommandConfig.cs 26 ●●●● 对比 | 查看 | 原始文档 | blame | 历史
Code/WCS/WIDESEAWCS_Server/WIDESEAWCS_Tasks/StackerCraneJob/StackerCraneDBName.cs 80 ●●●●● 对比 | 查看 | 原始文档 | blame | 历史
Code/WCS/WIDESEAWCS_Server/WIDESEAWCS_Tasks/StackerCraneJob/StackerCraneTaskCommand.cs 77 ●●●●● 对比 | 查看 | 原始文档 | blame | 历史
Code/WCS/WIDESEAWCS_Server/WIDESEAWCS_Tasks/StackerCraneJob/StackerCraneTaskSelector.cs 129 ●●●●● 对比 | 查看 | 原始文档 | blame | 历史