function sleep(NumMillis) { var nowTime = new Date(); var exitTime = nowTime .getTime() + NumMillis; while (true) { now = new Date(); if (now.getTime() > exitTime) return; } }
原文地址:https://www.cnblogs.com/bin521/p/8806914.html
时间: 2024-10-14 14:27:53