CustomPeerResolverService.RefreshInterval 属性

定义

获取或设置时间长度,在此时间段内,项将在对等解析程序服务的注册查找表中有效。Gets or sets the length of time that entries remain valid in a peer resolver service's registration lookup table.

public:
 property TimeSpan RefreshInterval { TimeSpan get(); void set(TimeSpan value); };
public TimeSpan RefreshInterval { get; set; }
member this.RefreshInterval : TimeSpan with get, set
Public Property RefreshInterval As TimeSpan

属性值

指定时间长度的 TimeSpan,在此时间段内,项将在对等解析程序服务的注册查找表中有效。TimeSpan that specifies the length of time that entries remain valid in a peer resolver service's registration lookup table.

异常

该时间间隔既可为零,也可大于 MaxValueThe interval is either zero or greater than MaxValue.

在调用 Open() 后,尝试设置该属性。An attempt to set the property was made after a call to Open().

注解

必须在执行对等解析程序服务之前设置此属性,且此属性不能为零。This property must be set before the peer resolver service has been and must not be zero. 默认时间间隔为 2 分钟。The default interval is 2 minutes.

对于对等解析程序服务的注册查找表中的给定项,当提供给此属性的时间段结束以后,该项将会被标记,以便删除。When the amount of time supplied to this property has passed for a given entry in a peer resolver service's registration lookup table, that entry is marked for deletion. CleanupInterval 属性中所指定的时间间隔结束以后,就会执行删除操作。The delete occurs when interval specified in the CleanupInterval property occurs. 例如,如果将此属性设置为 10 分钟,则注册查找表中的项将会在该时间间隔后,变为无效,且会被标记,以便删除。For example, if this property is set to a timespan of 10 minutes, entries in the registration lookup table will become stale and marked for deletion after the interval has passed. 因此,对等解析程序客户端必须每十分钟进行一次更新,以避免其项被删除。As a result, the peer resolver client must update every ten minutes to avoid having their entry deleted.

适用于