src/vs/workbench/contrib/terminal/browser/terminalService.ts/TerminalService/_getInstanceIdFromUri
class TerminalService:	private _getInstanceIdFromUri(resource: URI): number | undefined {
		if (resource.scheme !== Schemas.vscodeTerminal) {
			return undefined;
		}
		const base = basename(resource.path);
		if (base === '') {
			return undefined;
		}
		return parseInt(base);
	}