S
S
strelkovandreyv2019-05-07 20:17:15
Android
strelkovandreyv, 2019-05-07 20:17:15

What kind of Android torrent client exists with the ability to control it from the side?

Good afternoon, please tell me.
There is an Android device on which you need to download content via torrent,
but you need such functionality so that you can, as it were, give it a task from the outside
. it turns out initially the first device is only a workhorse,
and other third-party clients (ideally also on Android) could monitor its
download progress status, and the ability to transfer the task in the form of a .torrent file

Answer the question

In order to leave comments, you need to log in

4 answer(s)
B
brar, 2019-05-07
@brar

https://4pda.ru/forum/index.php?showtopic=356674
Worked before. Now xs.

D
Deodatuss, 2017-04-16
@Maks00088

if there is no setTimeout, then the logic looks like this:
print();
look at what i is now and print to the console
print()
look at what i is now and print to the console print() look at what i is now and
print
to the console
.....
If there is setTimeout, then the logic looks like this:
call print() when the stack calls will be empty(no code is being executed) but not earlier than 5 seconds later
call print() when the call stack is empty(no code is being executed) but not earlier than 5 seconds later
call print() when the call stack is empty(no code not executed) but not before 5 seconds
call print() when the call stack is empty (no code is executed) but not before 5 seconds
....
all code is executed
....
look at what i is now and print to the console
look at what i is now and print to the console
look at what i is now and print to the console
look at what i is now and print to the console
This is how it should work:

var i;
var print = function (i) {
    console.log(i);
}
for(i=0;i<10;i++){
   setTimeout(print.bind(null, i),5000);
}

UPD:
useful video on this topic

A
Alexander Aksentiev, 2017-04-16
@Sanasol

because the loop is over by the time the timeout starts running.

G
Grigory Matveev, 2017-04-16
@AgRuN

This is due to the fact that the first print is called 5 seconds after the timer was started, but the loop during this time performed more and more iterations on each of which it increased the value of the variable i by one until it became equal to 10, all these iterations took only a few milliseconds or tens of milliseconds. So, by the time print was called for the first time by the timer, the value of i was already 10 and never changed!

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question