Please wait. This can take some minutes ...
Many resources are needed to download a project. Please understand that we have to compensate our server costs. Thank you in advance.
Project price only 1 $
You can buy this project and download/modify it how often you want.
js.web.webrtc.RTCDataChannel Maven / Gradle / Ivy
package js.web.webrtc;
import js.web.channelmessaging.MessageEvent;
import js.web.dom.*;
import org.teavm.jso.JSBody;
import org.teavm.jso.JSProperty;
import javax.annotation.Nullable;
/**
* Created by Artem Godin on 1/22/2020.
*/
public interface RTCDataChannel extends EventTarget {
@JSBody(script = "return RTCDataChannel.prototype")
static RTCDataChannel prototype() {
throw new UnsupportedOperationException("Available only in JavaScript");
}
@JSBody(script = "return new RTCDataChannel()")
static RTCDataChannel create() {
throw new UnsupportedOperationException("Available only in JavaScript");
}
@JSProperty
String getBinaryType();
@JSProperty
void setBinaryType(String binaryType);
@JSProperty
int getBufferedAmount();
@JSProperty
int getBufferedAmountLowThreshold();
@JSProperty
void setBufferedAmountLowThreshold(int bufferedAmountLowThreshold);
@JSProperty
@Nullable
int getId();
@JSProperty
String getLabel();
@JSProperty
@Nullable
double getMaxPacketLifeTime();
@JSProperty
@Nullable
int getMaxRetransmits();
@JSProperty
boolean isNegotiated();
@JSProperty
@Nullable
EventListener getOnbufferedamountlow();
@JSProperty
void setOnbufferedamountlow(EventListener onbufferedamountlow);
default void addBufferedAmountLowEventListener(EventListener listener, AddEventListenerOptions options) {
addEventListener("bufferedamountlow", listener, options);
}
default void addBufferedAmountLowEventListener(EventListener listener, boolean options) {
addEventListener("bufferedamountlow", listener, options);
}
default void addBufferedAmountLowEventListener(EventListener listener) {
addEventListener("bufferedamountlow", listener);
}
default void removeBufferedAmountLowEventListener(EventListener listener, EventListenerOptions options) {
removeEventListener("bufferedamountlow", listener, options);
}
default void removeBufferedAmountLowEventListener(EventListener listener, boolean options) {
removeEventListener("bufferedamountlow", listener, options);
}
default void removeBufferedAmountLowEventListener(EventListener listener) {
removeEventListener("bufferedamountlow", listener);
}
@JSProperty
@Nullable
EventListener getOnclose();
@JSProperty
void setOnclose(EventListener onclose);
default void addCloseEventListener(EventListener listener, AddEventListenerOptions options) {
addEventListener("close", listener, options);
}
default void addCloseEventListener(EventListener listener, boolean options) {
addEventListener("close", listener, options);
}
default void addCloseEventListener(EventListener listener) {
addEventListener("close", listener);
}
default void removeCloseEventListener(EventListener listener, EventListenerOptions options) {
removeEventListener("close", listener, options);
}
default void removeCloseEventListener(EventListener listener, boolean options) {
removeEventListener("close", listener, options);
}
default void removeCloseEventListener(EventListener listener) {
removeEventListener("close", listener);
}
@JSProperty
@Nullable
EventListener getOnerror();
@JSProperty
void setOnerror(EventListener onerror);
default void addErrorEventListener(EventListener listener, AddEventListenerOptions options) {
addEventListener("error", listener, options);
}
default void addErrorEventListener(EventListener listener, boolean options) {
addEventListener("error", listener, options);
}
default void addErrorEventListener(EventListener listener) {
addEventListener("error", listener);
}
default void removeErrorEventListener(EventListener listener, EventListenerOptions options) {
removeEventListener("error", listener, options);
}
default void removeErrorEventListener(EventListener listener, boolean options) {
removeEventListener("error", listener, options);
}
default void removeErrorEventListener(EventListener listener) {
removeEventListener("error", listener);
}
@JSProperty
@Nullable
EventListener getOnmessage();
@JSProperty
void setOnmessage(EventListener onmessage);
default void addMessageEventListener(EventListener listener, AddEventListenerOptions options) {
addEventListener("message", listener, options);
}
default void addMessageEventListener(EventListener listener, boolean options) {
addEventListener("message", listener, options);
}
default void addMessageEventListener(EventListener listener) {
addEventListener("message", listener);
}
default void removeMessageEventListener(EventListener listener, EventListenerOptions options) {
removeEventListener("message", listener, options);
}
default void removeMessageEventListener(EventListener listener, boolean options) {
removeEventListener("message", listener, options);
}
default void removeMessageEventListener(EventListener listener) {
removeEventListener("message", listener);
}
@JSProperty
@Nullable
EventListener getOnopen();
@JSProperty
void setOnopen(EventListener onopen);
default void addOpenEventListener(EventListener listener, AddEventListenerOptions options) {
addEventListener("open", listener, options);
}
default void addOpenEventListener(EventListener listener, boolean options) {
addEventListener("open", listener, options);
}
default void addOpenEventListener(EventListener listener) {
addEventListener("open", listener);
}
default void removeOpenEventListener(EventListener listener, EventListenerOptions options) {
removeEventListener("open", listener, options);
}
default void removeOpenEventListener(EventListener listener, boolean options) {
removeEventListener("open", listener, options);
}
default void removeOpenEventListener(EventListener listener) {
removeEventListener("open", listener);
}
@JSProperty
boolean isOrdered();
@JSProperty
RTCPriorityType getPriority();
@JSProperty
String getProtocol();
@JSProperty
RTCDataChannelState getReadyState();
void close();
void send(String data);
void send(Blob data);
void send(BufferSource data);
}