C# 클래스 Squishy.Network.TrafficWatch

This class is required for Connection throtteling. When active, a thread will poll all given throttles every PollSpan. That means calculating an exact current speed of all their Connections and continue transfer of all throttled connections.
파일 보기 프로젝트 열기: jaddie/WCell-Utility-Bot

공개 메소드들

메소드 설명
Add ( Throttle throttle ) : void

Adds a new Throttle.

AddDownloadThrottle ( int maxDownBps ) : Throttle

Adds and returns a new SetThrottle which will restrict the total download speed of all its connections to the given value. Initial connections of the new throttle.

AddThrottle ( int maxUpBps, int maxDownBps ) : Throttle

Adds and returns a new SetThrottle which will restrict the total download speed and upload speeds of all its connections to the given values. Initial connections of the new throttle.

AddUploadThrottle ( int maxUpBps ) : Throttle

Adds and returns a new SetThrottle which will restrict the total upload speed of all its connections to the given value. Initial connections of the new throttle.

GetThrottle ( int index ) : Throttle
Remove ( Throttle throttle ) : void

Removes the given Throttle or does nothing if its not Active.

Remove ( int index ) : void
RemoveAll ( ) : void

Removes all Throttles.

비공개 메소드들

메소드 설명
PollAll ( ) : void
WaitPoll ( ) : void

메소드 상세

Add() 공개 정적인 메소드

Adds a new Throttle.
public static Add ( Throttle throttle ) : void
throttle Throttle
리턴 void

AddDownloadThrottle() 공개 정적인 메소드

Adds and returns a new SetThrottle which will restrict the total download speed of all its connections to the given value. Initial connections of the new throttle.
public static AddDownloadThrottle ( int maxDownBps ) : Throttle
maxDownBps int
리턴 Throttle

AddThrottle() 공개 정적인 메소드

Adds and returns a new SetThrottle which will restrict the total download speed and upload speeds of all its connections to the given values. Initial connections of the new throttle.
public static AddThrottle ( int maxUpBps, int maxDownBps ) : Throttle
maxUpBps int
maxDownBps int
리턴 Throttle

AddUploadThrottle() 공개 정적인 메소드

Adds and returns a new SetThrottle which will restrict the total upload speed of all its connections to the given value. Initial connections of the new throttle.
public static AddUploadThrottle ( int maxUpBps ) : Throttle
maxUpBps int
리턴 Throttle

GetThrottle() 공개 정적인 메소드

public static GetThrottle ( int index ) : Throttle
index int
리턴 Throttle

Remove() 공개 정적인 메소드

Removes the given Throttle or does nothing if its not Active.
public static Remove ( Throttle throttle ) : void
throttle Throttle
리턴 void

Remove() 공개 정적인 메소드

public static Remove ( int index ) : void
index int
리턴 void

RemoveAll() 공개 정적인 메소드

Removes all Throttles.
public static RemoveAll ( ) : void
리턴 void