YourKit 提供用于捕获 CPU 分析(采样/跟踪)的 API。像下面这样的东西......
import com.yourkit.api.Controller;
import java.awt.*;
import java.io.File;
/**
* to understand yourkit api.....
*/
public class AppMain {
public static void main(String[] args) throws Exception {
Controller yourKitController = new Controller();
yourKitController.startCPUSampling(null);
AnApplication anApplication = new AnApplication();
anApplication.count(1000090);
yourKitController.stopCPUProfiling();
String savedFilePath = yourKitController.captureSnapshot(Controller.SNAPSHOT_WITHOUT_HEAP);
File savedFile = new File(savedFilePath);
Desktop.getDesktop().open(savedFile);
}
}
我找不到用于分析捕获数据的 API。是否有用于分析捕获数据的 yourkit API?