elemental2.dom.ServiceWorkerRegistration Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of elemental2-dom Show documentation
Show all versions of elemental2-dom Show documentation
Thin Java abstractions for the native Browser APIs.
package elemental2.dom;
import elemental2.promise.Promise;
import jsinterop.annotations.JsFunction;
import jsinterop.annotations.JsPackage;
import jsinterop.annotations.JsProperty;
import jsinterop.annotations.JsType;
@JsType(isNative = true, namespace = JsPackage.GLOBAL)
public interface ServiceWorkerRegistration extends EventTarget {
@JsFunction
public interface OnupdatefoundFn {
Object onInvoke(Event event);
}
@JsProperty
ServiceWorker getActive();
@JsProperty
ServiceWorker getInstalling();
@JsProperty
NavigationPreloadManager getNavigationPreload();
Promise getNotifications();
Promise getNotifications(GetNotificationOptions filter);
@JsProperty
ServiceWorkerRegistration.OnupdatefoundFn getOnupdatefound();
@JsProperty
PushManager getPushManager();
@JsProperty
String getScope();
@JsProperty
SyncManager getSync();
@JsProperty
ServiceWorker getWaiting();
@JsProperty
void setActive(ServiceWorker active);
@JsProperty
void setInstalling(ServiceWorker installing);
@JsProperty
void setNavigationPreload(NavigationPreloadManager navigationPreload);
@JsProperty
void setOnupdatefound(ServiceWorkerRegistration.OnupdatefoundFn onupdatefound);
@JsProperty
void setPushManager(PushManager pushManager);
@JsProperty
void setScope(String scope);
@JsProperty
void setSync(SyncManager sync);
@JsProperty
void setWaiting(ServiceWorker waiting);
Promise showNotification(String title, NotificationOptions options);
Promise showNotification(String title);
Promise unregister();
Promise update();
}