Stream.WriteTimeout Stream.WriteTimeout Stream.WriteTimeout Stream.WriteTimeout Property

定义

获取或设置一个值(以毫秒为单位),该值确定流在超时前尝试写入多长时间。Gets or sets a value, in milliseconds, that determines how long the stream will attempt to write before timing out.

public:
 virtual property int WriteTimeout { int get(); void set(int value); };
[System.Runtime.InteropServices.ComVisible(false)]
public virtual int WriteTimeout { get; set; }
member this.WriteTimeout : int with get, set
Public Overridable Property WriteTimeout As Integer

属性值

一个确定流在超时前尝试写入多长时间的值(以毫秒为单位)。A value, in milliseconds, that determines how long the stream will attempt to write before timing out.

异常

继承者说明

WriteTimeout应重写属性,以提供适当的行为的流。The WriteTimeout property should be overridden to provide the appropriate behavior for the stream. 如果流不支持不会超时,此属性应引发InvalidOperationExceptionIf the stream does not support timing out, this property should raise an InvalidOperationException.

适用于