whyclxw
2024-12-23 93be23aaba651076443b87e662b0232dd1a03b75
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
package com.whyc.service;
 
import org.springframework.stereotype.Service;
 
import javax.annotation.Resource;
 
@Service
public class TestParamService {
 
 
 
    public void callService(int seconds) throws InterruptedException {
        //毫秒
        int milliseconds = seconds * 1000;
        int count = milliseconds/100;
        for (int i = 0; i < count; i++) {
            Thread.sleep(100);
        }
    }
}