js.web.dom.TextTrackList Maven / Gradle / Ivy
package js.web.dom;
import js.util.collections.ArrayLike;
import org.teavm.jso.JSBody;
import org.teavm.jso.JSProperty;
import javax.annotation.Nullable;
/**
* Created by Artem Godin on 1/23/2020.
*/
public interface TextTrackList extends ArrayLike, EventTarget {
@JSBody(script = "return TextTrackList.prototype")
static TextTrackList prototype() {
throw new UnsupportedOperationException("Available only in JavaScript");
}
@JSBody(script = "return new TextTrackList()")
static TextTrackList create() {
throw new UnsupportedOperationException("Available only in JavaScript");
}
@JSProperty
@Nullable
EventListener getOnaddtrack();
@JSProperty
void setOnaddtrack(EventListener onaddtrack);
default void addAddTrackEventListener(EventListener listener, AddEventListenerOptions options) {
addEventListener("addtrack", listener, options);
}
default void addAddTrackEventListener(EventListener listener, boolean options) {
addEventListener("addtrack", listener, options);
}
default void addAddTrackEventListener(EventListener listener) {
addEventListener("addtrack", listener);
}
default void removeAddTrackEventListener(EventListener listener, EventListenerOptions options) {
removeEventListener("addtrack", listener, options);
}
default void removeAddTrackEventListener(EventListener listener, boolean options) {
removeEventListener("addtrack", listener, options);
}
default void removeAddTrackEventListener(EventListener listener) {
removeEventListener("addtrack", listener);
}
TextTrack item(int index);
}