shouldStopSeeding

fun shouldStopSeeding(uploaded: Long, downloaded: Long, totalSize: Long, seedingSeconds: Long, ratioLimitPerMille: Int, seedTimeLimitSeconds: Int): Boolean

Return

true once either active limit is met.

Parameters

uploaded

total bytes uploaded for this torrent.

downloaded

total bytes downloaded (0 for a torrent added as a finished seed).

totalSize

the torrent's size. It is the floor for the ratio denominator, so a never-downloaded seed still has a meaningful ratio ("upload N× the torrent size").

seedingSeconds

seconds spent in the seeding state.

ratioLimitPerMille

share-ratio cap in per-mille (2000 = 2.0×); UNLIMITED = off.

seedTimeLimitSeconds

seed-time cap in seconds; UNLIMITED = off.