Packages

  • package root
    Definition Classes
    root
  • package scala
    Definition Classes
    root
  • package scalajs
    Definition Classes
    scala
  • package js

    Types, methods and values for interoperability with JavaScript libraries.

    Types, methods and values for interoperability with JavaScript libraries.

    This package is only relevant to the Scala.js compiler, and should not be referenced by any project compiled to the JVM.

    Guide

    General documentation on Scala.js is available at http://www.scala-js.org/doc/.

    Overview

    The trait js.Any is the root of the hierarchy of JavaScript types. This package defines important subtypes of js.Any that are defined in the standard library of ECMAScript 5.1 (or ES 6, with a label in the documentation), such as js.Object, js.Array and js.RegExp.

    Implicit conversions to and from standard Scala types to their equivalent in JavaScript are provided. For example, from Scala functions to JavaScript functions and back.

    The most important subtypes of js.Any declared in this package are:

    The trait js.Dynamic is a special subtrait of js.Any. It can represent any JavaScript value in a dynamically-typed way. It is possible to call any method and read and write any field of a value of type js.Dynamic.

    There are no explicit definitions for JavaScript primitive types, as one could expect, because the corresponding Scala types stand in their stead:

    • Boolean is the type of primitive JavaScript booleans
    • Double is the type of primitive JavaScript numbers
    • String is the type of primitive JavaScript strings (or null)
    • Unit is the type of the JavaScript undefined value
    • Null is the type of the JavaScript null value

    js.UndefOr gives a scala.Option-like interface where the JavaScript value undefined takes the role of None.

    A | B is an unboxed pseudo-union type, suitable to type values that admit several unrelated types in facade types.

    Definition Classes
    scalajs
  • package annotation
    Definition Classes
    js
  • package timers

    Non-Standard Non-standard, but in general well supported methods to schedule asynchronous execution.

    Non-Standard Non-standard, but in general well supported methods to schedule asynchronous execution.

    The methods in this package work in all JavaScript virtual machines supporting setTimeout and setInterval.

    Definition Classes
    js
  • package typedarray

    ECMAScript 6 The typdearray package provides facade types for JavaScript ArrayBuffer, TypeArrays and DataView.

    ECMAScript 6 The typdearray package provides facade types for JavaScript ArrayBuffer, TypeArrays and DataView. Further, it provides conversions between primitive Scala arrays and TypedArrays

    Definition Classes
    js
  • AB2TA
  • AC2TA
  • AD2TA
  • AF2TA
  • AI2TA
  • AS2TA
  • ArrayBuffer
  • ArrayBufferView
  • BigInt64Array
  • BigUint64Array
  • DataView
  • DataViewExt
  • Float32Array
  • Float64Array
  • Int16Array
  • Int32Array
  • Int8Array
  • TA2AB
  • TA2AC
  • TA2AD
  • TA2AF
  • TA2AI
  • TA2AS
  • TypedArray
  • TypedArrayBuffer
  • TypedArrayBufferOps
  • TypedArrayStatic
  • Uint16Array
  • Uint32Array
  • Uint8Array
  • Uint8ClampedArray
p

scala.scalajs.js

typedarray

package typedarray

ECMAScript 6 The typdearray package provides facade types for JavaScript ArrayBuffer, TypeArrays and DataView. Further, it provides conversions between primitive Scala arrays and TypedArrays

Linear Supertypes
Ordering
  1. Alphabetic
  2. By Inheritance
Inherited
  1. typedarray
  2. AnyRef
  3. Any
  1. Hide All
  2. Show All
Visibility
  1. Public
  2. All

Type Members

  1. implicit final class AB2TA extends AnyVal

    ECMAScript 6 Adds toTypedArray conversion to an Array[Byte]

  2. implicit final class AC2TA extends AnyVal

    ECMAScript 6 Adds toTypedArray conversion to an Array[Char]

  3. implicit final class AD2TA extends AnyVal

    ECMAScript 6 Adds toTypedArray conversion to an Array[Double]

  4. implicit final class AF2TA extends AnyVal

    ECMAScript 6 Adds toTypedArray conversion to an Array[Float]

  5. implicit final class AI2TA extends AnyVal

    ECMAScript 6 Adds toTypedArray conversion to an Array[Int]

  6. implicit final class AS2TA extends AnyVal

    ECMAScript 6 Adds toTypedArray conversion to an Array[Short]

  7. class ArrayBuffer extends Object

    ECMAScript 6 An ArrayBuffer is a block of contiguous, non-resizable memory.

    ECMAScript 6 An ArrayBuffer is a block of contiguous, non-resizable memory.

    Annotations
    @JSType() @native() @JSGlobal()
  8. trait ArrayBufferView extends Object

    ECMAScript 6 An ArrayBufferView allows accessing the data of an ArrayBuffer

    ECMAScript 6 An ArrayBufferView allows accessing the data of an ArrayBuffer

    Annotations
    @JSType() @native()
  9. class BigInt64Array extends Object with TypedArray[BigInt, BigInt64Array]

    ECMAScript 2019

    ECMAScript 2019

    A TypedArray of signed 64-bit integers represented as js.BigInt.

    Annotations
    @JSType() @native() @JSGlobal()
  10. class BigUint64Array extends Object with TypedArray[BigInt, BigUint64Array]

    ECMAScript 2019

    ECMAScript 2019

    A TypedArray of unsigned 64-bit integers represented as js.BigInt.

    Annotations
    @JSType() @native() @JSGlobal()
  11. class DataView extends Object with ArrayBufferView

    ECMAScript 6 A DataView allows for extraction of particular data types at specific offsets.

    ECMAScript 6 A DataView allows for extraction of particular data types at specific offsets.

    Annotations
    @JSType() @native() @JSGlobal()
  12. class Float32Array extends Object with TypedArray[Float, Float32Array]

    ECMAScript 6 A TypedArray of single precision floats

    ECMAScript 6 A TypedArray of single precision floats

    Annotations
    @JSType() @native() @JSGlobal()
  13. class Float64Array extends Object with TypedArray[Double, Float64Array]

    ECMAScript 6 A TypedArray of double precision floats

    ECMAScript 6 A TypedArray of double precision floats

    Annotations
    @JSType() @native() @JSGlobal()
  14. class Int16Array extends Object with TypedArray[Short, Int16Array]

    ECMAScript 6 A TypedArray of signed 16-bit integers

    ECMAScript 6 A TypedArray of signed 16-bit integers

    Annotations
    @JSType() @native() @JSGlobal()
  15. class Int32Array extends Object with TypedArray[Int, Int32Array]

    ECMAScript 6 A TypedArray of signed 32-bit integers

    ECMAScript 6 A TypedArray of signed 32-bit integers

    Annotations
    @JSType() @native() @JSGlobal()
  16. class Int8Array extends Object with TypedArray[Byte, Int8Array]

    ECMAScript 6 A TypedArray of signed 8-bit integers

    ECMAScript 6 A TypedArray of signed 8-bit integers

    Annotations
    @JSType() @native() @JSGlobal()
  17. implicit final class TA2AB extends AnyVal

    ECMAScript 6 Adds toArray conversion to a Int8Array

  18. implicit final class TA2AC extends AnyVal

    ECMAScript 6 Adds toArray conversion to a Uint16Array

  19. implicit final class TA2AD extends AnyVal

    ECMAScript 6 Adds toArray conversion to a Float64Array

  20. implicit final class TA2AF extends AnyVal

    ECMAScript 6 Adds toArray conversion to a Float32Array

  21. implicit final class TA2AI extends AnyVal

    ECMAScript 6 Adds toArray conversion to a Int32Array

  22. implicit final class TA2AS extends AnyVal

    ECMAScript 6 Adds toArray conversion to a Int16Array

  23. trait TypedArray[T, Repr] extends Object with ArrayBufferView with Iterable[T]

    ECMAScript 6 A TypedArray allows to view an ArrayBuffer as an array of values of a particular numeric type.

    ECMAScript 6 A TypedArray allows to view an ArrayBuffer as an array of values of a particular numeric type.

    Annotations
    @JSType() @native()
  24. final class TypedArrayBufferOps[TypedArrayType <: TypedArray[_, TypedArrayType]] extends AnyVal

    Additional operations on a Buffer with interoperability with JavaScript Typed Arrays.

    Additional operations on a Buffer with interoperability with JavaScript Typed Arrays.

    All Scala.js implementations of Buffer also implement this interface for some TypedArrayType, which depends on the type of elements in the buffer.

  25. trait TypedArrayStatic[T, Repr] extends Object

    ECMAScript 6 Static information that exists for any concrete TypedArray

    ECMAScript 6 Static information that exists for any concrete TypedArray

    Annotations
    @JSType() @native()
  26. class Uint16Array extends Object with TypedArray[Int, Uint16Array]

    ECMAScript 6 A TypedArray of unsigned 16-bit integers

    ECMAScript 6 A TypedArray of unsigned 16-bit integers

    Annotations
    @JSType() @native() @JSGlobal()
  27. class Uint32Array extends Object with TypedArray[Double, Uint32Array]

    ECMAScript 6 A TypedArray of unsigned 32-bit integers

    ECMAScript 6 A TypedArray of unsigned 32-bit integers

    Annotations
    @JSType() @native() @JSGlobal()
  28. class Uint8Array extends Object with TypedArray[Short, Uint8Array]

    ECMAScript 6 A TypedArray of unsigned 8-bit integers

    ECMAScript 6 A TypedArray of unsigned 8-bit integers

    Annotations
    @JSType() @native() @JSGlobal()
  29. class Uint8ClampedArray extends Object with TypedArray[Int, Uint8ClampedArray]

    ECMAScript 6 A TypedArray of unsigned 8-bit integers whose values are clamped to their max/min rather than wrapped around if they overflow.

    ECMAScript 6 A TypedArray of unsigned 8-bit integers whose values are clamped to their max/min rather than wrapped around if they overflow.

    Annotations
    @JSType() @native() @JSGlobal()

Value Members

  1. def byteArray2Int8Array(array: scala.Array[Byte]): Int8Array
  2. def charArray2Uint16Array(array: scala.Array[Char]): Uint16Array
  3. def doubleArray2Float64Array(array: scala.Array[Double]): Float64Array
  4. def float32Array2FloatArray(array: Float32Array): scala.Array[Float]
  5. def float64Array2DoubleArray(array: Float64Array): scala.Array[Double]
  6. def floatArray2Float32Array(array: scala.Array[Float]): Float32Array
  7. def int16Array2ShortArray(array: Int16Array): scala.Array[Short]
  8. def int32Array2IntArray(array: Int32Array): scala.Array[Int]
  9. def int8Array2ByteArray(array: Int8Array): scala.Array[Byte]
  10. def intArray2Int32Array(array: scala.Array[Int]): Int32Array
  11. def shortArray2Int16Array(array: scala.Array[Short]): Int16Array
  12. def uint16Array2CharArray(array: Uint16Array): scala.Array[Char]
  13. object BigInt64Array extends Object with TypedArrayStatic[BigInt, BigInt64Array]

    ECMAScript 2019 BigInt64Array companion

    ECMAScript 2019 BigInt64Array companion

    Annotations
    @native() @JSGlobal()
  14. object BigUint64Array extends Object with TypedArrayStatic[BigInt, BigUint64Array]

    ECMAScript 2019 BigUint64Array companion

    ECMAScript 2019 BigUint64Array companion

    Annotations
    @native() @JSGlobal()
  15. object DataViewExt

    Extensions for DataView.

  16. object Float32Array extends Object with TypedArrayStatic[Float, Float32Array]

    ECMAScript 6 Float32Array companion

    ECMAScript 6 Float32Array companion

    Annotations
    @native() @JSGlobal()
  17. object Float64Array extends Object with TypedArrayStatic[Double, Float64Array]

    ECMAScript 6 Float64Array companion

    ECMAScript 6 Float64Array companion

    Annotations
    @native() @JSGlobal()
  18. object Int16Array extends Object with TypedArrayStatic[Short, Int16Array]

    ECMAScript 6 Int16Array companion

    ECMAScript 6 Int16Array companion

    Annotations
    @native() @JSGlobal()
  19. object Int32Array extends Object with TypedArrayStatic[Int, Int32Array]

    ECMAScript 6 Int32Array companion

    ECMAScript 6 Int32Array companion

    Annotations
    @native() @JSGlobal()
  20. object Int8Array extends Object with TypedArrayStatic[Byte, Int8Array]

    ECMAScript 6 Int8Array companion

    ECMAScript 6 Int8Array companion

    Annotations
    @native() @JSGlobal()
  21. object TypedArrayBuffer

    Factory methods to create direct buffers from Typed Arrays.

    Factory methods to create direct buffers from Typed Arrays.

    All buffers created by the methods of this object are direct buffers with the native byte order of the platform.

  22. object TypedArrayBufferOps

    Extensions to Buffers for interoperability with JavaScript Typed Arrays.

  23. object Uint16Array extends Object with TypedArrayStatic[Int, Uint16Array]

    ECMAScript 6 Uint16Array companion

    ECMAScript 6 Uint16Array companion

    Annotations
    @native() @JSGlobal()
  24. object Uint32Array extends Object with TypedArrayStatic[Double, Uint32Array]

    ECMAScript 6 Uint32Array companion

    ECMAScript 6 Uint32Array companion

    Annotations
    @native() @JSGlobal()
  25. object Uint8Array extends Object with TypedArrayStatic[Short, Uint8Array]

    ECMAScript 6 Uint8Array companion

    ECMAScript 6 Uint8Array companion

    Annotations
    @native() @JSGlobal()
  26. object Uint8ClampedArray extends Object with TypedArrayStatic[Int, Uint8ClampedArray]

    ECMAScript 6 Uint8ClampedArray companion

    ECMAScript 6 Uint8ClampedArray companion

    Annotations
    @native() @JSGlobal()

Inherited from AnyRef

Inherited from scala.Any

Ungrouped