Class SMConst
java.lang.Object
com.biglybt.core.speedmanager.impl.v2.SMConst
-
Nested Class Summary
Nested Classes -
Field Summary
FieldsModifier and TypeFieldDescriptionstatic final intstatic final intstatic final intstatic final intstatic final int -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic longcalculateMinDownload(long maxBytesPerSec) static longcalculateMinUpload(long maxBytesPerSec) Rule: Min value is always 10% of max, but not below 5k.static longcheckForMinDownloadValue(long rateBytesPerSec) static longcheckForMinUploadValue(long rateBytesPerSec) No limit should go below 5k bytes/sec.static SpeedManagerLimitEstimatefilterEstimate(SpeedManagerLimitEstimate estimate, int startValue) Early in the search process the ping-mapper can give estimates that are too low due to a lack of information.static longfilterLimit(long bytesPerSec, int startValue)
-
Field Details
-
START_DOWNLOAD_RATE_MAX
public static final int START_DOWNLOAD_RATE_MAX- See Also:
-
START_UPLOAD_RATE_MAX
public static final int START_UPLOAD_RATE_MAX- See Also:
-
MIN_UPLOAD_BYTES_PER_SEC
public static final int MIN_UPLOAD_BYTES_PER_SEC- See Also:
-
MIN_DOWNLOAD_BYTES_PER_SEC
public static final int MIN_DOWNLOAD_BYTES_PER_SEC- See Also:
-
RATE_UNLIMITED
public static final int RATE_UNLIMITED- See Also:
-
-
Constructor Details
-
SMConst
private SMConst()
-
-
Method Details
-
checkForMinUploadValue
public static long checkForMinUploadValue(long rateBytesPerSec) No limit should go below 5k bytes/sec.- Parameters:
rateBytesPerSec- -- Returns:
- - "bytes/sec" rate.
-
checkForMinDownloadValue
public static long checkForMinDownloadValue(long rateBytesPerSec) -
calculateMinUpload
public static long calculateMinUpload(long maxBytesPerSec) Rule: Min value is always 10% of max, but not below 5k.- Parameters:
maxBytesPerSec- -- Returns:
- - minRate.
-
calculateMinDownload
public static long calculateMinDownload(long maxBytesPerSec) -
filterEstimate
public static SpeedManagerLimitEstimate filterEstimate(SpeedManagerLimitEstimate estimate, int startValue) Early in the search process the ping-mapper can give estimates that are too low due to a lack of information. The starting upload and download limits is 60K/30K should not go below the starting value a slow DSL lines should.- Parameters:
estimate- - download rate estimate.startValue- - starting upload/download value.- Returns:
- -
-
filterLimit
public static long filterLimit(long bytesPerSec, int startValue)
-