public interface TrafficCollector
| Modifier and Type | Method and Description |
|---|---|
static TrafficCollectorImpl.Builder |
builder(WebDriverFactory webDriverFactory)
Returns a new builder instance.
|
<R> HarPlus<R> |
collect(TrafficGenerator<R> generator)
Collects traffic generated by the given generator into a HAR.
|
<R> HarPlus<R> |
collect(TrafficGenerator<R> generator,
TrafficMonitor monitor)
Collects traffic generated by the given generator into a HAR.
|
<R> R |
drive(TrafficGenerator<R> generator)
Causes traffic to be generated by the given generator and returns the result.
|
<R> R |
monitor(TrafficGenerator<R> generator,
TrafficMonitor monitor)
Monitors traffic generated by the given generator.
|
<R> HarPlus<R> collect(TrafficGenerator<R> generator) throws IOException, org.openqa.selenium.WebDriverException
collect(TrafficGenerator, TrafficMonitor) with a null monitor reference.R - type of result the generator returnsgenerator - the generatorIOException - if something I/O related goes awryorg.openqa.selenium.WebDriverException - if the web driver could not be created or the generator throws one<R> HarPlus<R> collect(TrafficGenerator<R> generator, @Nullable TrafficMonitor monitor) throws IOException, org.openqa.selenium.WebDriverException
R - type of result the generator returnsgenerator - the generatormonitor - a monitor, or nullIOException - on I/O errororg.openqa.selenium.WebDriverException - if the web driver could not be created or the generator throws one<R> R monitor(TrafficGenerator<R> generator, TrafficMonitor monitor) throws IOException, org.openqa.selenium.WebDriverException
collect(TrafficGenerator, TrafficMonitor) but without capturing a HAR.R - generator result typegenerator - the traffic generatormonitor - the monitorIOException - on I/O errororg.openqa.selenium.WebDriverException - on webdriver error<R> R drive(TrafficGenerator<R> generator) throws IOException, org.openqa.selenium.WebDriverException
monitor(TrafficGenerator, TrafficMonitor) without
notifying a monitor of request/response interactions.R - generator result typegenerator - the traffic generatorIOException - on I/O errororg.openqa.selenium.WebDriverException - on webdriver errorstatic TrafficCollectorImpl.Builder builder(WebDriverFactory webDriverFactory)
webDriverFactory - the webdriver factoryCopyright © 2016–2018. All rights reserved.