| <!DOCTYPE html> |
| <html> |
| <head> |
| <meta charset="utf-8"> |
| <title>Namespace OpenQA.Selenium.DevTools.V148.Target </title> |
| <meta name="viewport" content="width=device-width, initial-scale=1.0"> |
| <meta name="title" content="Namespace OpenQA.Selenium.DevTools.V148.Target "> |
| |
| |
| <link rel="icon" href="../images/favicon.ico"> |
| <link rel="stylesheet" href="../public/docfx.min.css"> |
| <link rel="stylesheet" href="../public/main.css"> |
| <meta name="docfx:navrel" content="../toc.html"> |
| <meta name="docfx:tocrel" content="toc.html"> |
| |
| <meta name="docfx:rel" content="../"> |
| |
| |
| |
| <meta name="loc:inThisArticle" content="In this article"> |
| <meta name="loc:searchResultsCount" content="{count} results for "{query}""> |
| <meta name="loc:searchNoResults" content="No results for "{query}""> |
| <meta name="loc:tocFilter" content="Filter by title"> |
| <meta name="loc:nextArticle" content="Next"> |
| <meta name="loc:prevArticle" content="Previous"> |
| <meta name="loc:themeLight" content="Light"> |
| <meta name="loc:themeDark" content="Dark"> |
| <meta name="loc:themeAuto" content="Auto"> |
| <meta name="loc:changeTheme" content="Change theme"> |
| <meta name="loc:copy" content="Copy"> |
| <meta name="loc:downloadPdf" content="Download PDF"> |
| |
| <script type="module" src="./../public/docfx.min.js"></script> |
| |
| <script> |
| const theme = localStorage.getItem('theme') || 'auto' |
| document.documentElement.setAttribute('data-bs-theme', theme === 'auto' ? (window.matchMedia('(prefers-color-scheme: dark)').matches ? 'dark' : 'light') : theme) |
| </script> |
| |
| </head> |
| |
| <body class="tex2jax_ignore" data-layout="" data-yaml-mime="ManagedReference"> |
| <header class="bg-body border-bottom"> |
| <nav id="autocollapse" class="navbar navbar-expand-md" role="navigation"> |
| <div class="container-xxl flex-nowrap"> |
| <a class="navbar-brand" href="../index.html"> |
| <img id="logo" class="svg" src="../images/logo.svg" alt="Selenium .NET API"> |
| Selenium .NET API |
| </a> |
| <button class="btn btn-lg d-md-none border-0" type="button" data-bs-toggle="collapse" data-bs-target="#navpanel" aria-controls="navpanel" aria-expanded="false" aria-label="Toggle navigation"> |
| <i class="bi bi-three-dots"></i> |
| </button> |
| <div class="collapse navbar-collapse" id="navpanel"> |
| <div id="navbar"> |
| <form class="search" role="search" id="search"> |
| <i class="bi bi-search"></i> |
| <input class="form-control" id="search-query" type="search" disabled placeholder="Search" autocomplete="off" aria-label="Search"> |
| </form> |
| </div> |
| </div> |
| </div> |
| </nav> |
| </header> |
| |
| <main class="container-xxl"> |
| <div class="toc-offcanvas"> |
| <div class="offcanvas-md offcanvas-start" tabindex="-1" id="tocOffcanvas" aria-labelledby="tocOffcanvasLabel"> |
| <div class="offcanvas-header"> |
| <h5 class="offcanvas-title" id="tocOffcanvasLabel">Table of Contents</h5> |
| <button type="button" class="btn-close" data-bs-dismiss="offcanvas" data-bs-target="#tocOffcanvas" aria-label="Close"></button> |
| </div> |
| <div class="offcanvas-body"> |
| <nav class="toc" id="toc"></nav> |
| </div> |
| </div> |
| </div> |
| |
| <div class="content"> |
| <div class="actionbar"> |
| <button class="btn btn-lg border-0 d-md-none" type="button" data-bs-toggle="offcanvas" data-bs-target="#tocOffcanvas" aria-controls="tocOffcanvas" aria-expanded="false" aria-label="Show table of contents"> |
| <i class="bi bi-list"></i> |
| </button> |
| |
| <nav id="breadcrumb"></nav> |
| </div> |
| |
| <article data-uid="OpenQA.Selenium.DevTools.V148.Target"> |
| |
| <h1 id="OpenQA_Selenium_DevTools_V148_Target" data-uid="OpenQA.Selenium.DevTools.V148.Target" class="text-break">Namespace OpenQA.Selenium.DevTools.V148.Target</h1> |
| <div class="markdown level0 summary"></div> |
| <div class="markdown level0 conceptual"></div> |
| <div class="markdown level0 remarks"></div> |
| |
| <h3 id="classes"> |
| Classes |
| </h3> |
| <dl class="jumplist"> |
| <dt><a class="xref" href="OpenQA.Selenium.DevTools.V148.Target.ActivateTargetCommandResponse.html">ActivateTargetCommandResponse</a></dt> |
| <dd><p>Response for Activates (focuses) the target.</p> |
| </dd> |
| </dl> |
| <dl class="jumplist"> |
| <dt><a class="xref" href="OpenQA.Selenium.DevTools.V148.Target.ActivateTargetCommandSettings.html">ActivateTargetCommandSettings</a></dt> |
| <dd><p>Activates (focuses) the target.</p> |
| </dd> |
| </dl> |
| <dl class="jumplist"> |
| <dt><a class="xref" href="OpenQA.Selenium.DevTools.V148.Target.AttachToBrowserTargetCommandResponse.html">AttachToBrowserTargetCommandResponse</a></dt> |
| <dd><p>Response for Attaches to the browser target, only uses flat sessionId mode.</p> |
| </dd> |
| </dl> |
| <dl class="jumplist"> |
| <dt><a class="xref" href="OpenQA.Selenium.DevTools.V148.Target.AttachToBrowserTargetCommandSettings.html">AttachToBrowserTargetCommandSettings</a></dt> |
| <dd><p>Attaches to the browser target, only uses flat sessionId mode.</p> |
| </dd> |
| </dl> |
| <dl class="jumplist"> |
| <dt><a class="xref" href="OpenQA.Selenium.DevTools.V148.Target.AttachToTargetCommandResponse.html">AttachToTargetCommandResponse</a></dt> |
| <dd><p>Response for Attaches to the target with given id.</p> |
| </dd> |
| </dl> |
| <dl class="jumplist"> |
| <dt><a class="xref" href="OpenQA.Selenium.DevTools.V148.Target.AttachToTargetCommandSettings.html">AttachToTargetCommandSettings</a></dt> |
| <dd><p>Attaches to the target with given id.</p> |
| </dd> |
| </dl> |
| <dl class="jumplist"> |
| <dt><a class="xref" href="OpenQA.Selenium.DevTools.V148.Target.AttachedToTargetEventArgs.html">AttachedToTargetEventArgs</a></dt> |
| <dd><p>Issued when attached to target because of auto-attach or <code>attachToTarget</code> command.</p> |
| </dd> |
| </dl> |
| <dl class="jumplist"> |
| <dt><a class="xref" href="OpenQA.Selenium.DevTools.V148.Target.AutoAttachRelatedCommandResponse.html">AutoAttachRelatedCommandResponse</a></dt> |
| <dd><p>Response for Adds the specified target to the list of targets that will be monitored for any related target |
| creation (such as child frames, child workers and new versions of service worker) and reported |
| through <code>attachedToTarget</code>. The specified target is also auto-attached. |
| This cancels the effect of any previous <code>setAutoAttach</code> and is also cancelled by subsequent |
| <code>setAutoAttach</code>. Only available at the Browser target.</p> |
| </dd> |
| </dl> |
| <dl class="jumplist"> |
| <dt><a class="xref" href="OpenQA.Selenium.DevTools.V148.Target.AutoAttachRelatedCommandSettings.html">AutoAttachRelatedCommandSettings</a></dt> |
| <dd><p>Adds the specified target to the list of targets that will be monitored for any related target |
| creation (such as child frames, child workers and new versions of service worker) and reported |
| through <code>attachedToTarget</code>. The specified target is also auto-attached. |
| This cancels the effect of any previous <code>setAutoAttach</code> and is also cancelled by subsequent |
| <code>setAutoAttach</code>. Only available at the Browser target.</p> |
| </dd> |
| </dl> |
| <dl class="jumplist"> |
| <dt><a class="xref" href="OpenQA.Selenium.DevTools.V148.Target.CloseTargetCommandResponse.html">CloseTargetCommandResponse</a></dt> |
| <dd><p>Response for Closes the target. If the target is a page that gets closed too.</p> |
| </dd> |
| </dl> |
| <dl class="jumplist"> |
| <dt><a class="xref" href="OpenQA.Selenium.DevTools.V148.Target.CloseTargetCommandSettings.html">CloseTargetCommandSettings</a></dt> |
| <dd><p>Closes the target. If the target is a page that gets closed too.</p> |
| </dd> |
| </dl> |
| <dl class="jumplist"> |
| <dt><a class="xref" href="OpenQA.Selenium.DevTools.V148.Target.CreateBrowserContextCommandResponse.html">CreateBrowserContextCommandResponse</a></dt> |
| <dd><p>Response for Creates a new empty BrowserContext. Similar to an incognito profile but you can have more than |
| one.</p> |
| </dd> |
| </dl> |
| <dl class="jumplist"> |
| <dt><a class="xref" href="OpenQA.Selenium.DevTools.V148.Target.CreateBrowserContextCommandSettings.html">CreateBrowserContextCommandSettings</a></dt> |
| <dd><p>Creates a new empty BrowserContext. Similar to an incognito profile but you can have more than |
| one.</p> |
| </dd> |
| </dl> |
| <dl class="jumplist"> |
| <dt><a class="xref" href="OpenQA.Selenium.DevTools.V148.Target.CreateTargetCommandResponse.html">CreateTargetCommandResponse</a></dt> |
| <dd><p>Response for Creates a new page.</p> |
| </dd> |
| </dl> |
| <dl class="jumplist"> |
| <dt><a class="xref" href="OpenQA.Selenium.DevTools.V148.Target.CreateTargetCommandSettings.html">CreateTargetCommandSettings</a></dt> |
| <dd><p>Creates a new page.</p> |
| </dd> |
| </dl> |
| <dl class="jumplist"> |
| <dt><a class="xref" href="OpenQA.Selenium.DevTools.V148.Target.DetachFromTargetCommandResponse.html">DetachFromTargetCommandResponse</a></dt> |
| <dd><p>Response for Detaches session with given id.</p> |
| </dd> |
| </dl> |
| <dl class="jumplist"> |
| <dt><a class="xref" href="OpenQA.Selenium.DevTools.V148.Target.DetachFromTargetCommandSettings.html">DetachFromTargetCommandSettings</a></dt> |
| <dd><p>Detaches session with given id.</p> |
| </dd> |
| </dl> |
| <dl class="jumplist"> |
| <dt><a class="xref" href="OpenQA.Selenium.DevTools.V148.Target.DetachedFromTargetEventArgs.html">DetachedFromTargetEventArgs</a></dt> |
| <dd><p>Issued when detached from target for any reason (including <code>detachFromTarget</code> command). Can be |
| issued multiple times per target if multiple sessions have been attached to it.</p> |
| </dd> |
| </dl> |
| <dl class="jumplist"> |
| <dt><a class="xref" href="OpenQA.Selenium.DevTools.V148.Target.DisposeBrowserContextCommandResponse.html">DisposeBrowserContextCommandResponse</a></dt> |
| <dd><p>Response for Deletes a BrowserContext. All the belonging pages will be closed without calling their |
| beforeunload hooks.</p> |
| </dd> |
| </dl> |
| <dl class="jumplist"> |
| <dt><a class="xref" href="OpenQA.Selenium.DevTools.V148.Target.DisposeBrowserContextCommandSettings.html">DisposeBrowserContextCommandSettings</a></dt> |
| <dd><p>Deletes a BrowserContext. All the belonging pages will be closed without calling their |
| beforeunload hooks.</p> |
| </dd> |
| </dl> |
| <dl class="jumplist"> |
| <dt><a class="xref" href="OpenQA.Selenium.DevTools.V148.Target.ExposeDevToolsProtocolCommandResponse.html">ExposeDevToolsProtocolCommandResponse</a></dt> |
| <dd><p>Response for Inject object to the target's main frame that provides a communication |
| channel with browser target.</p> |
| <p>Injected object will be available as <code>window[bindingName]</code>.</p> |
| <p>The object has the following API:</p> |
| <ul> |
| <li><code>binding.send(json)</code> - a method to send messages over the remote debugging protocol</li> |
| <li><code>binding.onmessage = json => handleMessage(json)</code> - a callback that will be called for the protocol notifications and command responses.</li> |
| </ul> |
| </dd> |
| </dl> |
| <dl class="jumplist"> |
| <dt><a class="xref" href="OpenQA.Selenium.DevTools.V148.Target.ExposeDevToolsProtocolCommandSettings.html">ExposeDevToolsProtocolCommandSettings</a></dt> |
| <dd><p>Inject object to the target's main frame that provides a communication |
| channel with browser target.</p> |
| <p>Injected object will be available as <code>window[bindingName]</code>.</p> |
| <p>The object has the following API:</p> |
| <ul> |
| <li><code>binding.send(json)</code> - a method to send messages over the remote debugging protocol</li> |
| <li><code>binding.onmessage = json => handleMessage(json)</code> - a callback that will be called for the protocol notifications and command responses.</li> |
| </ul> |
| </dd> |
| </dl> |
| <dl class="jumplist"> |
| <dt><a class="xref" href="OpenQA.Selenium.DevTools.V148.Target.FilterEntry.html">FilterEntry</a></dt> |
| <dd><p>A filter used by target query/discovery/auto-attach operations.</p> |
| </dd> |
| </dl> |
| <dl class="jumplist"> |
| <dt><a class="xref" href="OpenQA.Selenium.DevTools.V148.Target.GetBrowserContextsCommandResponse.html">GetBrowserContextsCommandResponse</a></dt> |
| <dd><p>Response for Returns all browser contexts created with <code>Target.createBrowserContext</code> method.</p> |
| </dd> |
| </dl> |
| <dl class="jumplist"> |
| <dt><a class="xref" href="OpenQA.Selenium.DevTools.V148.Target.GetBrowserContextsCommandSettings.html">GetBrowserContextsCommandSettings</a></dt> |
| <dd><p>Returns all browser contexts created with <code>Target.createBrowserContext</code> method.</p> |
| </dd> |
| </dl> |
| <dl class="jumplist"> |
| <dt><a class="xref" href="OpenQA.Selenium.DevTools.V148.Target.GetDevToolsTargetCommandResponse.html">GetDevToolsTargetCommandResponse</a></dt> |
| <dd><p>Response for Gets the targetId of the DevTools page target opened for the given target |
| (if any).</p> |
| </dd> |
| </dl> |
| <dl class="jumplist"> |
| <dt><a class="xref" href="OpenQA.Selenium.DevTools.V148.Target.GetDevToolsTargetCommandSettings.html">GetDevToolsTargetCommandSettings</a></dt> |
| <dd><p>Gets the targetId of the DevTools page target opened for the given target |
| (if any).</p> |
| </dd> |
| </dl> |
| <dl class="jumplist"> |
| <dt><a class="xref" href="OpenQA.Selenium.DevTools.V148.Target.GetTargetInfoCommandResponse.html">GetTargetInfoCommandResponse</a></dt> |
| <dd><p>Response for Returns information about a target.</p> |
| </dd> |
| </dl> |
| <dl class="jumplist"> |
| <dt><a class="xref" href="OpenQA.Selenium.DevTools.V148.Target.GetTargetInfoCommandSettings.html">GetTargetInfoCommandSettings</a></dt> |
| <dd><p>Returns information about a target.</p> |
| </dd> |
| </dl> |
| <dl class="jumplist"> |
| <dt><a class="xref" href="OpenQA.Selenium.DevTools.V148.Target.GetTargetsCommandResponse.html">GetTargetsCommandResponse</a></dt> |
| <dd><p>Response for Retrieves a list of available targets.</p> |
| </dd> |
| </dl> |
| <dl class="jumplist"> |
| <dt><a class="xref" href="OpenQA.Selenium.DevTools.V148.Target.GetTargetsCommandSettings.html">GetTargetsCommandSettings</a></dt> |
| <dd><p>Retrieves a list of available targets.</p> |
| </dd> |
| </dl> |
| <dl class="jumplist"> |
| <dt><a class="xref" href="OpenQA.Selenium.DevTools.V148.Target.OpenDevToolsCommandResponse.html">OpenDevToolsCommandResponse</a></dt> |
| <dd><p>Response for Opens a DevTools window for the target.</p> |
| </dd> |
| </dl> |
| <dl class="jumplist"> |
| <dt><a class="xref" href="OpenQA.Selenium.DevTools.V148.Target.OpenDevToolsCommandSettings.html">OpenDevToolsCommandSettings</a></dt> |
| <dd><p>Opens a DevTools window for the target.</p> |
| </dd> |
| </dl> |
| <dl class="jumplist"> |
| <dt><a class="xref" href="OpenQA.Selenium.DevTools.V148.Target.ReceivedMessageFromTargetEventArgs.html">ReceivedMessageFromTargetEventArgs</a></dt> |
| <dd><p>Notifies about a new protocol message received from the session (as reported in |
| <code>attachedToTarget</code> event).</p> |
| </dd> |
| </dl> |
| <dl class="jumplist"> |
| <dt><a class="xref" href="OpenQA.Selenium.DevTools.V148.Target.RemoteLocation.html">RemoteLocation</a></dt> |
| <dd><p>RemoteLocation</p> |
| </dd> |
| </dl> |
| <dl class="jumplist"> |
| <dt><a class="xref" href="OpenQA.Selenium.DevTools.V148.Target.SendMessageToTargetCommandResponse.html">SendMessageToTargetCommandResponse</a></dt> |
| <dd><p>Response for Sends protocol message over session with given id. |
| Consider using flat mode instead; see commands attachToTarget, setAutoAttach, |
| and crbug.com/991325.</p> |
| </dd> |
| </dl> |
| <dl class="jumplist"> |
| <dt><a class="xref" href="OpenQA.Selenium.DevTools.V148.Target.SendMessageToTargetCommandSettings.html">SendMessageToTargetCommandSettings</a></dt> |
| <dd><p>Sends protocol message over session with given id. |
| Consider using flat mode instead; see commands attachToTarget, setAutoAttach, |
| and crbug.com/991325.</p> |
| </dd> |
| </dl> |
| <dl class="jumplist"> |
| <dt><a class="xref" href="OpenQA.Selenium.DevTools.V148.Target.SetAutoAttachCommandResponse.html">SetAutoAttachCommandResponse</a></dt> |
| <dd><p>Response for Controls whether to automatically attach to new targets which are considered |
| to be directly related to this one (for example, iframes or workers). |
| When turned on, attaches to all existing related targets as well. When turned off, |
| automatically detaches from all currently attached targets. |
| This also clears all targets added by <code>autoAttachRelated</code> from the list of targets to watch |
| for creation of related targets. |
| You might want to call this recursively for auto-attached targets to attach |
| to all available targets.</p> |
| </dd> |
| </dl> |
| <dl class="jumplist"> |
| <dt><a class="xref" href="OpenQA.Selenium.DevTools.V148.Target.SetAutoAttachCommandSettings.html">SetAutoAttachCommandSettings</a></dt> |
| <dd><p>Controls whether to automatically attach to new targets which are considered |
| to be directly related to this one (for example, iframes or workers). |
| When turned on, attaches to all existing related targets as well. When turned off, |
| automatically detaches from all currently attached targets. |
| This also clears all targets added by <code>autoAttachRelated</code> from the list of targets to watch |
| for creation of related targets. |
| You might want to call this recursively for auto-attached targets to attach |
| to all available targets.</p> |
| </dd> |
| </dl> |
| <dl class="jumplist"> |
| <dt><a class="xref" href="OpenQA.Selenium.DevTools.V148.Target.SetDiscoverTargetsCommandResponse.html">SetDiscoverTargetsCommandResponse</a></dt> |
| <dd><p>Response for Controls whether to discover available targets and notify via |
| <code>targetCreated/targetInfoChanged/targetDestroyed</code> events.</p> |
| </dd> |
| </dl> |
| <dl class="jumplist"> |
| <dt><a class="xref" href="OpenQA.Selenium.DevTools.V148.Target.SetDiscoverTargetsCommandSettings.html">SetDiscoverTargetsCommandSettings</a></dt> |
| <dd><p>Controls whether to discover available targets and notify via |
| <code>targetCreated/targetInfoChanged/targetDestroyed</code> events.</p> |
| </dd> |
| </dl> |
| <dl class="jumplist"> |
| <dt><a class="xref" href="OpenQA.Selenium.DevTools.V148.Target.SetRemoteLocationsCommandResponse.html">SetRemoteLocationsCommandResponse</a></dt> |
| <dd><p>Response for Enables target discovery for the specified locations, when <code>setDiscoverTargets</code> was set to |
| <code>true</code>.</p> |
| </dd> |
| </dl> |
| <dl class="jumplist"> |
| <dt><a class="xref" href="OpenQA.Selenium.DevTools.V148.Target.SetRemoteLocationsCommandSettings.html">SetRemoteLocationsCommandSettings</a></dt> |
| <dd><p>Enables target discovery for the specified locations, when <code>setDiscoverTargets</code> was set to |
| <code>true</code>.</p> |
| </dd> |
| </dl> |
| <dl class="jumplist"> |
| <dt><a class="xref" href="OpenQA.Selenium.DevTools.V148.Target.TargetAdapter.html">TargetAdapter</a></dt> |
| <dd><p>Represents an adapter for the Target domain to simplify the command interface.</p> |
| </dd> |
| </dl> |
| <dl class="jumplist"> |
| <dt><a class="xref" href="OpenQA.Selenium.DevTools.V148.Target.TargetCrashedEventArgs.html">TargetCrashedEventArgs</a></dt> |
| <dd><p>Issued when a target has crashed.</p> |
| </dd> |
| </dl> |
| <dl class="jumplist"> |
| <dt><a class="xref" href="OpenQA.Selenium.DevTools.V148.Target.TargetCreatedEventArgs.html">TargetCreatedEventArgs</a></dt> |
| <dd><p>Issued when a possible inspection target is created.</p> |
| </dd> |
| </dl> |
| <dl class="jumplist"> |
| <dt><a class="xref" href="OpenQA.Selenium.DevTools.V148.Target.TargetDestroyedEventArgs.html">TargetDestroyedEventArgs</a></dt> |
| <dd><p>Issued when a target is destroyed.</p> |
| </dd> |
| </dl> |
| <dl class="jumplist"> |
| <dt><a class="xref" href="OpenQA.Selenium.DevTools.V148.Target.TargetInfo.html">TargetInfo</a></dt> |
| <dd><p>TargetInfo</p> |
| </dd> |
| </dl> |
| <dl class="jumplist"> |
| <dt><a class="xref" href="OpenQA.Selenium.DevTools.V148.Target.TargetInfoChangedEventArgs.html">TargetInfoChangedEventArgs</a></dt> |
| <dd><p>Issued when some information about a target has changed. This only happens between |
| <code>targetCreated</code> and <code>targetDestroyed</code>.</p> |
| </dd> |
| </dl> |
| <h3 id="enums"> |
| Enums |
| </h3> |
| <dl class="jumplist"> |
| <dt><a class="xref" href="OpenQA.Selenium.DevTools.V148.Target.WindowState.html">WindowState</a></dt> |
| <dd><p>The state of the target window.</p> |
| </dd> |
| </dl> |
| |
| |
| </article> |
| |
| <div class="contribution d-print-none"> |
| </div> |
| |
| |
| </div> |
| |
| <div class="affix"> |
| <nav id="affix"></nav> |
| </div> |
| </main> |
| |
| <div class="container-xxl search-results" id="search-results"></div> |
| |
| <footer class="border-top text-secondary"> |
| <div class="container-xxl"> |
| <div class="flex-fill"> |
| <span>Made with <a href="https://dotnet.github.io/docfx">docfx</a></span> |
| </div> |
| </div> |
| </footer> |
| </body> |
| </html> |