点击或拖拽改变大小

NetworkXBaseReceiveFileFromSocket 方法 (Socket, Stream, ActionInt64, Int64)

[自校验] 从网络中接收一个文件,写入数据流,如果结果异常,则结束通讯,参数顺序文件名,文件大小,文件标识,上传人
[Self-checking] Receive a file from the network. If the result is abnormal, the communication ends.

命名空间:  HslCommunication.Core.Net
程序集:  HslCommunication (在 HslCommunication.dll 中) 版本:11.8.2.0 (11.8.2.0)
语法
protected OperateResult<FileBaseInfo> ReceiveFileFromSocket(
	Socket socket,
	Stream stream,
	Action<long, long> receiveReport
)

参数

socket
类型:System.Net.SocketsSocket
网络套接字
stream
类型:System.IOStream
等待写入的数据流
receiveReport
类型:SystemActionInt64, Int64
接收进度报告

返回值

类型:OperateResultFileBaseInfo
文件头结果
参见