org.openqa.selenium.devtools.v122.tethering.Tethering Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of selenium-devtools-v122 Show documentation
Show all versions of selenium-devtools-v122 Show documentation
Selenium automates browsers. That's it! What you do with that power is entirely up to you.
package org.openqa.selenium.devtools.v122.tethering;
import org.openqa.selenium.Beta;
import org.openqa.selenium.devtools.Command;
import org.openqa.selenium.devtools.Event;
import org.openqa.selenium.devtools.ConverterFunctions;
import java.util.Map;
import java.util.LinkedHashMap;
import org.openqa.selenium.json.JsonInput;
/**
* The Tethering domain defines methods and events for browser port binding.
*/
@Beta()
public class Tethering {
/**
* Request browser port binding.
*/
public static Command bind(java.lang.Integer port) {
java.util.Objects.requireNonNull(port, "port is required");
LinkedHashMap params = new LinkedHashMap<>();
params.put("port", port);
return new Command<>("Tethering.bind", Map.copyOf(params));
}
/**
* Request browser port unbinding.
*/
public static Command unbind(java.lang.Integer port) {
java.util.Objects.requireNonNull(port, "port is required");
LinkedHashMap params = new LinkedHashMap<>();
params.put("port", port);
return new Command<>("Tethering.unbind", Map.copyOf(params));
}
public static Event accepted() {
return new Event<>("Tethering.accepted", input -> input.read(org.openqa.selenium.devtools.v122.tethering.model.Accepted.class));
}
}