All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.openqa.selenium.devtools.v90.inspector.Inspector Maven / Gradle / Ivy

Go to download

Selenium automates browsers. That's it! What you do with that power is entirely up to you.

There is a newer version: 4.0.0-beta-4
Show newest version
package org.openqa.selenium.devtools.v90.inspector;

import org.openqa.selenium.Beta;
import org.openqa.selenium.devtools.Command;
import org.openqa.selenium.devtools.Event;
import org.openqa.selenium.devtools.ConverterFunctions;
import com.google.common.collect.ImmutableMap;
import org.openqa.selenium.json.JsonInput;

@Beta()
public class Inspector {

    /**
     * Disables inspector domain notifications.
     */
    public static Command disable() {
        ImmutableMap.Builder params = ImmutableMap.builder();
        return new Command<>("Inspector.disable", params.build());
    }

    /**
     * Enables inspector domain notifications.
     */
    public static Command enable() {
        ImmutableMap.Builder params = ImmutableMap.builder();
        return new Command<>("Inspector.enable", params.build());
    }

    public static Event detached() {
        return new Event<>("Inspector.detached", ConverterFunctions.map("reason", java.lang.String.class));
    }

    public static Event targetCrashed() {
        return new Event<>("Inspector.targetCrashed", input -> null);
    }

    public static Event targetReloadedAfterCrash() {
        return new Event<>("Inspector.targetReloadedAfterCrash", input -> null);
    }
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy