Here you can find the source of sleep(int milliseconds, boolean isRecordMode)
Parameter | Description |
---|---|
milliseconds | time in milliseconds for which to sleep. |
public static void sleep(int milliseconds, boolean isRecordMode)
//package com.java2s; /**//from w ww . j a va 2 s .c o m * Copyright (c) Microsoft Corporation. All rights reserved. * Licensed under the MIT License. See License.txt in the project root for * license information. */ public class Main { /** * Wrapper on the Thread.sleep, in case of record mode will not sleep, otherwise sleep. * @param milliseconds time in milliseconds for which to sleep. */ public static void sleep(int milliseconds, boolean isRecordMode) { if (isRecordMode) { try { Thread.sleep(milliseconds); } catch (InterruptedException e) { e.printStackTrace(); } } } }