Dart.Ftp Namespace > FtpSession Class : MaxRate Property |
<DefaultValueAttribute(0)> Public Property MaxRate As Integer
Dim instance As FtpSession Dim value As Integer instance.MaxRate = value value = instance.MaxRate
[DefaultValue(0)] public int MaxRate {get; set;}
[DefaultValue(0)] public: property int MaxRate { int get(); void set ( int value); }
The default value of 0 indicates that all available bandwidth will be used.
This property is used to throttle the speed of data transfer and can be changed during a transfer.
/// <summary> /// Limits the transfer rate of the provided Ftp instance /// </summary> /// <param name="myFtp">Ftp instance to throttle transfer rate for</param> /// <param name="maxRate">Transfer rate limit, in bytes per second</param> public void ThrottleFtp(Ftp myFtp, int maxRate) { myFtp.Session.MaxRate = maxRate; }
''' <summary> ''' Limits the transfer rate of the provided Ftp instance ''' </summary> ''' <param name="myFtp">Ftp instance to throttle transfer rate for</param> ''' <param name="maxRate">Transfer rate limit, in bytes per second</param> Public Sub ThrottleFtp(ByVal myFtp As Ftp, ByVal maxRate As Integer) myFtp.Session.MaxRate = maxRate End Sub