MCPcopy Create free account
hub / github.com/Marus/cortex-debug / waitForPortStatus

Method waitForPortStatus

src/tcpportscanner.ts:343–349  ·  view source on GitHub ↗

* Wait for particular port status. We always do a minium of one try regardless of timeouts, so setting a timeout * of 0 means only one try * * @param inUse true means wait for port to be ready to use. False means wait for port to close * @return a promise. On failure, the error

(
        port, host = TcpPortScanner.DefaultHost, inUse = true,
        checkLocalHostAliaes = true, retryTimeMs = 100, timeOutMs = 5000)

Source from the content-addressed store, hash-verified

341 * for other failures
342 */
343 public static waitForPortStatus(
344 port, host = TcpPortScanner.DefaultHost, inUse = true,
345 checkLocalHostAliaes = true, retryTimeMs = 100, timeOutMs = 5000): Promise<void> {
346 retryTimeMs = Math.max(retryTimeMs, 1);
347 const opts = new PortStatusArgs(inUse, port, host, checkLocalHostAliaes, retryTimeMs, timeOutMs);
348 return TcpPortScanner.waitForPortStatusEx(opts);
349 }
350
351 /**
352 * Wait for port to open. We always do a minium of one try regardless of timeouts, so setting a timeout

Callers

nothing calls this directly

Calls 1

waitForPortStatusExMethod · 0.45

Tested by

no test coverage detected