I'm currently developing a small auto-reply bot using Mathematica, and a key barrier is to send a reply whenever the webpage updates, in other words, new messages come in.
I cannot think of any efficient method of doing this, the only thing that came to my mind is to constantly import the HTML page by RunScheduledTask
and compare the difference between consecutive ones. But this method requires constant HTML downloading and comparing which is rather low in efficiency and low in updating speed. So I'm here to find out whether there are any better methods.
To simplify the problem, let's say, I would like Mathematica to print the present time to the front-end whenever mathematica.stackexchange.com updates.(when new questions or answers come in)
I want the update lag as short as possible and CPU consumption as little as possible. I would like to offer a bounty if a really satisfying answer(or answers) comes in~
Thanks!!!
Note: maybe package WebUnit will help. Check here for details.
Comments
Post a Comment