WorkerNavigator extension type

The WorkerNavigator interface represents a subset of the Navigator interface allowed to be accessed from a Worker. Such an object is initialized for each worker and is available via the WorkerGlobalScope.navigator property.


API documentation sourced from MDN Web Docs.

on
Implemented types
Available extensions

Properties

appCodeName String
The value of the WorkerNavigator.appCodeName property is always "Mozilla", in any browser. This property is kept only for compatibility purposes.
no setter
appName String
The value of the WorkerNavigator.appName property is always "Netscape", in any browser. This property is kept only for compatibility purposes.
no setter
appVersion String
Returns either "4.0" or a string representing version information about the browser.
no setter
connection NetworkInformation
The connection read-only property of the WorkerNavigator interface returns a NetworkInformation object containing information about the system's connection, such as the current bandwidth of the user's device or whether the connection is metered. This could be used to select high definition content or low definition content based on the user's connection.
no setter
deviceMemory double
The deviceMemory read-only property of the WorkerNavigator interface returns the approximate amount of device memory in gigabytes.
no setter
hardwareConcurrency int
The navigator.hardwareConcurrency read-only property returns the number of logical processors available to run threads on the user's computer.
no setter
hashCode int
The hash code for this object.
no setterinherited
isDefinedAndNotNull bool

Available on JSAny?, provided by the NullableUndefineableJSAnyExtension extension

no setter
isNull bool

Available on JSAny?, provided by the NullableUndefineableJSAnyExtension extension

Whether this value corresponds to JavaScript null.
no setter
isTruthy JSBoolean

Available on JSAny?, provided by the JSAnyOperatorExtension extension

The result of !!this in JavaScript.
no setter
isUndefined bool

Available on JSAny?, provided by the NullableUndefineableJSAnyExtension extension

Whether this value corresponds to JavaScript undefined.
no setter
isUndefinedOrNull bool

Available on JSAny?, provided by the NullableUndefineableJSAnyExtension extension

no setter
language String
The WorkerNavigator.language read-only property returns a string representing the preferred language of the user, usually the language of the browser UI.
no setter
languages JSArray<JSString>
The WorkerNavigator.languages read-only property returns an array of strings representing the user's preferred languages. The language is described using language tags according to 5646, "Tags for Identifying Languages (also known as BCP 47)". In the returned array they are ordered by preference with the most preferred language first.
no setter
locks LockManager
The locks read-only property of the WorkerNavigator interface returns a LockManager object which provides methods for requesting a new Lock object and querying for an existing Lock object.
no setter
mediaCapabilities MediaCapabilities
The read-only WorkerNavigator.mediaCapabilities property returns a MediaCapabilities object that can expose information about the decoding and encoding capabilities for a given format and output capabilities as defined by the Media Capabilities API.
no setter
not JSBoolean

Available on JSAny?, provided by the JSAnyOperatorExtension extension

The result of !this in JavaScript.
no setter
onLine bool
Returns the online status of the browser. The property returns a boolean value, with true meaning online and false meaning offline. The property sends updates whenever the browser's ability to connect to the network changes. The update occurs when the user follows links or when a script requests a remote page.
no setter
permissions Permissions
The permissions read-only property of the WorkerNavigator interface returns a Permissions object that can be used to query and update permission status of APIs covered by the Permissions API.
no setter
platform String
Returns a string representing the platform of the browser. The specification allows browsers to always return the empty string, so don't rely on this property to get a reliable answer.
no setter
product String
The value of the WorkerNavigator.product property is always "Gecko", in any browser. This property is kept only for compatibility purposes.
no setter
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
serviceWorker ServiceWorkerContainer
The serviceWorker read-only property of the WorkerNavigator interface returns the ServiceWorkerContainer object for the associated document, which provides access to registration, removal, upgrade, and communication with the ServiceWorker.
no setter
storage StorageManager
The storage read-only property of the WorkerNavigator interface returns the singleton StorageManager object used to access the overall storage capabilities of the browser for the current site or app. The returned object lets you examine and configure persistence of data stores and learn approximately how much more space your browser has available for local storage use.
no setter
usb JSObject
The usb read-only property of the WorkerNavigator interface returns a USB object for the current document, providing access to WebUSB API functionality.
no setter
userAgent String
The WorkerNavigator.userAgent read-only property returns the user agent string for the current browser.
no setter

Methods

add(JSAny? any) JSAny

Available on JSAny?, provided by the JSAnyOperatorExtension extension

The result of this + any in JavaScript.
and(JSAny? any) JSAny?

Available on JSAny?, provided by the JSAnyOperatorExtension extension

The result of this && any in JavaScript.
callMethod<R extends JSAny?>(JSAny method, [JSAny? arg1, JSAny? arg2, JSAny? arg3, JSAny? arg4]) → R

Available on JSObject, provided by the JSObjectUnsafeUtilExtension extension

Calls method on this JSObject with up to four arguments.
callMethodVarArgs<R extends JSAny?>(JSAny method, [List<JSAny?>? arguments]) → R

Available on JSObject, provided by the JSObjectUnsafeUtilExtension extension

Calls method on this JSObject with a variable number of arguments.
dartify() Object?

Available on JSAny?, provided by the JSAnyUtilityExtension extension

Converts a JavaScript value to the Dart equivalent if possible.
delete(JSAny property) JSBoolean

Available on JSObject, provided by the JSObjectUnsafeUtilExtension extension

Deletes the property with key property from this JSObject.
divide(JSAny? any) JSAny

Available on JSAny?, provided by the JSAnyOperatorExtension extension

The result of this / any in JavaScript.
equals(JSAny? any) JSBoolean

Available on JSAny?, provided by the JSAnyOperatorExtension extension

The result of this == any in JavaScript.
exponentiate(JSAny? any) JSAny

Available on JSAny?, provided by the JSAnyOperatorExtension extension

The result of this ** any in JavaScript.
getProperty<R extends JSAny?>(JSAny property) → R

Available on JSObject, provided by the JSObjectUnsafeUtilExtension extension

The value of the property key property of this JSObject.
greaterThan(JSAny? any) JSBoolean

Available on JSAny?, provided by the JSAnyOperatorExtension extension

The result of this > any in JavaScript.
greaterThanOrEqualTo(JSAny? any) JSBoolean

Available on JSAny?, provided by the JSAnyOperatorExtension extension

The result of this >= any in JavaScript.
has(String property) bool

Available on JSObject, provided by the JSObjectUnsafeUtilExtension extension

Shorthand helper for hasProperty to check whether this JSObject contains the property key property, but takes and returns a Dart value.
hasProperty(JSAny property) JSBoolean

Available on JSObject, provided by the JSObjectUnsafeUtilExtension extension

Whether or not this JSObject contains the property key property.
instanceof(JSFunction constructor) bool

Available on JSAny?, provided by the JSAnyUtilityExtension extension

Whether this JSAny? is an instanceof constructor.
instanceOfString(String constructorName) bool

Available on JSAny?, provided by the JSAnyUtilityExtension extension

Whether this JSAny? is an instanceof the constructor that is defined by constructorName, which is looked up in the globalContext.
isA<T extends JSAny?>() bool

Available on JSAny?, provided by the JSAnyUtilityExtension extension

Whether this JSAny? is an instance of the JavaScript type that is declared by T.
lessThan(JSAny? any) JSBoolean

Available on JSAny?, provided by the JSAnyOperatorExtension extension

The result of this < any in JavaScript.
lessThanOrEqualTo(JSAny? any) JSBoolean

Available on JSAny?, provided by the JSAnyOperatorExtension extension

The result of this <= any in JavaScript.
modulo(JSAny? any) JSAny

Available on JSAny?, provided by the JSAnyOperatorExtension extension

The result of this % any in JavaScript.
multiply(JSAny? any) JSAny

Available on JSAny?, provided by the JSAnyOperatorExtension extension

The result of this * any in JavaScript.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
notEquals(JSAny? any) JSBoolean

Available on JSAny?, provided by the JSAnyOperatorExtension extension

The result of this != any in JavaScript.
or(JSAny? any) JSAny?

Available on JSAny?, provided by the JSAnyOperatorExtension extension

The result of this || any in JavaScript.
setProperty(JSAny property, JSAny? value) → void

Available on JSObject, provided by the JSObjectUnsafeUtilExtension extension

Write the value of property key property of this JSObject.
strictEquals(JSAny? any) JSBoolean

Available on JSAny?, provided by the JSAnyOperatorExtension extension

The result of this === any in JavaScript.
strictNotEquals(JSAny? any) JSBoolean

Available on JSAny?, provided by the JSAnyOperatorExtension extension

The result of this !== any in JavaScript.
subtract(JSAny? any) JSAny

Available on JSAny?, provided by the JSAnyOperatorExtension extension

The result of this - any in JavaScript.
toString() String
A string representation of this object.
inherited
typeofEquals(String typeString) bool

Available on JSAny?, provided by the JSAnyUtilityExtension extension

Whether the result of typeof on this JSAny? is typeString.
unsignedRightShift(JSAny? any) JSNumber

Available on JSAny?, provided by the JSAnyOperatorExtension extension

The result of this >>> any in JavaScript.

Operators

operator ==(Object other) bool
The equality operator.
inherited
operator [](String property) JSAny?

Available on JSObject, provided by the JSObjectUnsafeUtilExtension extension

Shorthand helper for getProperty to get the value of the property key property of this JSObject, but takes and returns a Dart value.
operator []=(String property, JSAny? value) → void

Available on JSObject, provided by the JSObjectUnsafeUtilExtension extension

Shorthand helper for setProperty to write the value of the property key property of this JSObject, but takes a Dart value.