Class BidiBrowserEventCollector
java.lang.Object
com.shaft.capture.collector.BidiBrowserEventCollector
- All Implemented Interfaces:
BrowserEventCollector, AutoCloseable
WebDriver BiDi collector using preload scripts for immediate cross-context signals.
-
Constructor Summary
ConstructorsConstructorDescriptionBidiBrowserEventCollector(org.openqa.selenium.WebDriver driver) Creates a BiDi collector.BidiBrowserEventCollector(org.openqa.selenium.WebDriver driver, List<String> testIdAttributes) Creates a BiDi collector.BidiBrowserEventCollector(org.openqa.selenium.WebDriver driver, List<String> testIdAttributes, String stepsEndpoint, String stepsToken) Creates a BiDi collector with a steps-rehydration endpoint so the recorder UI can source its step list from the server-side session store across navigations, including cross-origin ones, instead of page-scoped storage.BidiBrowserEventCollector(org.openqa.selenium.WebDriver driver, List<String> testIdAttributes, String stepsEndpoint, String stepsToken, String eventEndpoint, String eventToken) Creates a BiDi collector whose preload script also posts every signal to the loopback event sink, so preload-installed recorder instances have two delivery channels (the BiDi script channel and the HTTP sink). -
Method Summary
-
Constructor Details
-
BidiBrowserEventCollector
public BidiBrowserEventCollector(org.openqa.selenium.WebDriver driver) Creates a BiDi collector.- Parameters:
driver- BiDi-capable driver
-
BidiBrowserEventCollector
-
BidiBrowserEventCollector
public BidiBrowserEventCollector(org.openqa.selenium.WebDriver driver, List<String> testIdAttributes, String stepsEndpoint, String stepsToken) Creates a BiDi collector with a steps-rehydration endpoint so the recorder UI can source its step list from the server-side session store across navigations, including cross-origin ones, instead of page-scoped storage.- Parameters:
driver- BiDi-capable drivertestIdAttributes- locator test-id attributesstepsEndpoint- optional loopback steps query endpointstepsToken- optional loopback steps query token
-
BidiBrowserEventCollector
public BidiBrowserEventCollector(org.openqa.selenium.WebDriver driver, List<String> testIdAttributes, String stepsEndpoint, String stepsToken, String eventEndpoint, String eventToken) Creates a BiDi collector whose preload script also posts every signal to the loopback event sink, so preload-installed recorder instances have two delivery channels (the BiDi script channel and the HTTP sink). Single-channel preload delivery lost signals from back/forward-cache restored pages.- Parameters:
driver- BiDi-capable drivertestIdAttributes- locator test-id attributesstepsEndpoint- optional loopback steps query endpointstepsToken- optional loopback steps query tokeneventEndpoint- optional loopback event endpointeventToken- optional loopback event token
-
-
Method Details
-
start
Description copied from interface:BrowserEventCollectorStarts event collection.- Specified by:
startin interfaceBrowserEventCollector- Parameters:
signalConsumer- signal destinationwarningConsumer- safe warning destination
-
close
public void close()Description copied from interface:BrowserEventCollectorStops collection and releases protocol listeners.- Specified by:
closein interfaceAutoCloseable- Specified by:
closein interfaceBrowserEventCollector
-