org.openqa.selenium.devtools.v85.media.Media Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of selenium-devtools-v85 Show documentation
Show all versions of selenium-devtools-v85 Show documentation
Selenium automates browsers. That's it! What you do with that power is entirely up to you.
package org.openqa.selenium.devtools.v85.media;
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;
/**
* This domain allows detailed inspection of media elements
*/
@Beta()
public class Media {
/**
* Enables the Media domain
*/
public static Command enable() {
ImmutableMap.Builder params = ImmutableMap.builder();
return new Command<>("Media.enable", params.build());
}
/**
* Disables the Media domain.
*/
public static Command disable() {
ImmutableMap.Builder params = ImmutableMap.builder();
return new Command<>("Media.disable", params.build());
}
public static Event playerPropertiesChanged() {
return new Event<>("Media.playerPropertiesChanged", input -> input.read(org.openqa.selenium.devtools.v85.media.model.PlayerPropertiesChanged.class));
}
public static Event playerEventsAdded() {
return new Event<>("Media.playerEventsAdded", input -> input.read(org.openqa.selenium.devtools.v85.media.model.PlayerEventsAdded.class));
}
public static Event playerMessagesLogged() {
return new Event<>("Media.playerMessagesLogged", input -> input.read(org.openqa.selenium.devtools.v85.media.model.PlayerMessagesLogged.class));
}
public static Event playerErrorsRaised() {
return new Event<>("Media.playerErrorsRaised", input -> input.read(org.openqa.selenium.devtools.v85.media.model.PlayerErrorsRaised.class));
}
public static Event> playersCreated() {
return new Event<>("Media.playersCreated", ConverterFunctions.map("players", new com.google.common.reflect.TypeToken>() {
}.getType()));
}
}