lib/built-in.jsx

The file defines the APIs of the built-in objects of JSX, designed to be compatible to the 3rd edition of the ECMA-262 standard whenever possible.

The description of the API is based on the MDN JavaScript Reference under the Creative Commons: Attribution-Sharealike license.

final native class Map.<T>

Map is an associative container that contains a list of unique key-value pairs. Type of the keys are strings, type of the values are Nullable.<T>.

function hasOwnProperty(key : string) : boolean

Returns a boolean indicating whether the object has the specified property.
key The name of the property to test.

function keys() : Array.<string>

Returns an array of keys of the map.

final native class Array.<T>

Array is a sequence of Nullable.<T> values. The size of an array is not fixed.

Unless otherwise noted, the defintions of the methods match those specified in ECMA-262, 3rd edition.

var length : number

A positive integer between 0 and a value less than 232 that specifies the number of elements in an array.

You can set the length property to truncate an array at any time. When you extend an array by changing its length property, the created elements are initialized to null.

new Array()

Constructs an empty array.

new Array(length : number)

Constructs an array of given length. The elements are initialized to null.

override function toString() : string

Returns a string representing the object.

function toLocaleString() : string

Returns a string representing the object.

function concat(arrayN : ...Array.<T>) : Array.<T>

Returns a new array comprised of this array joined with other array(s) and/or value(s).
arrayN Arrays to concatenate to the resulting array.

function join() : string

Joins all elements of an array into a string, separating each element with a comma.

function join(separator : string) : string

Joins all elements of an array into a string.
separator Specifies a string to separate each element of the array.

function pop() : Nullable.<T>

Removes the last element from an array and returns that element.

function push(itemN : ...Nullable.<T>) : int

Mutates an array by appending the given elements and returning the new length of the array.
itemN The elements to add to the end of the array.

function reverse() : Array.<T>

Reverses an array in place. The first array element becomes the last and the last becomes the first.

function shift() : Nullable.<T>

Removes the first element from an array and returns that element. This method changes the length of the array.

function slice(start : number) : Array.<T>

Returns a one-level deep copy of a portion of an array.
start Zero-based index at which to begin extraction.

function slice(start : number, end : number) : Array.<T>

Returns a one-level deep copy of a portion of an array.
start Zero-based index at which to begin extraction.
end Zero-based index at which to end extraction. slice extracts up to but not including end.

function sort() : Array.<T>

Sorts the elements of an array in place and returns the array. The sort is not necessarily stable. The array is sorted lexicographically (in dictionary order) according to the string conversion of each element.

function sort(comparefn : function (:Nullable.<T>, :Nullable.<T>) : number) : Array.<T>

Sorts the elements of an array in place and returns the array. The sort is not necessarily stable.
comparefn Specifies a function that defines the sort order.

function splice(start : number, deleteCount : number, itemN : ...T) : Array.<T>

Changes the content of an array, adding new elements while removing old elements.
start Index at which to start changing the array. If negative, will begin that many elements from the end.
deleteCount An integer indicating the number of old array elements to remove.
itemN The elements to add to the array. If you don't specify any elements, splice simply removes elements from the array.

function unshift(itemN : ...Nullable.<T>) : int

Adds one or more elements to the beginning of an array and returns the new length of the array.
itemN The elements to add to the front of the array.

function indexOf(value : Nullable.<T>) : number

Returns the first index at which a given element can be found in the array, or -1 if it is not present.

function indexOf(value : Nullable.<T>, fromIndex : number) : number

function lastIndexOf(value : Nullable.<T>) : number

Returns the last index at which a given element can be found in the array, or -1 if it is not present. The array is searched backward.

function lastIndexOf(value : Nullable.<T>, fromIndex : number) : number

function every(callbackfn : function (:Nullable.<T>) : boolean) : boolean

Tests whether all elements in the array pass the test implemented by the provided function.

function every(callbackfn : function (:Nullable.<T>, :number) : boolean) : boolean

function every(callbackfn : function (:Nullable.<T>, :number, :Array.<T>) : boolean) : boolean

function some(callbackfn : function (:Nullable.<T>) : boolean) : boolean

Tests whether some element in the array passes the test implemented by the provided function.

function some(callbackfn : function (:Nullable.<T>, :number) : boolean) : boolean

function some(callbackfn : function (:Nullable.<T>, :number, :Array.<T>) : boolean) : boolean

function forEach(callbackfn : function (:Nullable.<T>) : void) : void

Calls callbackfn once for each element in the array, in ascending order.
callbackfn A function to call for each element.

function forEach(callbackfn : function (:Nullable.<T>, :number) : void) : void

function forEach(callbackfn : function (:Nullable.<T>, :number, :Array.<T>) : void) : void

function filter(callbackfn : function (:Nullable.<T>) : boolean) : Array.<T>

Creates a new array with all elements that pass the test implemented the provided function.
callbackfn A function to test each elements of the array.

function filter(callbackfn : function (:Nullable.<T>, :number) : boolean) : Array.<T>

function filter(callbackfn : function (:Nullable.<T>, :number, :Array.<T>) : boolean) : Array.<T>

native class IteratorResult.<T>

var done : boolean

var value : Nullable.<T>

native class Generator.<SeedT, GenT>

function next() : IteratorResult.<GenT>

function next(seed : Nullable.<SeedT>) : IteratorResult.<GenT>

final native class Promise.<T>

new Promise(executor : function (:function (:T) : void, :function (:variant) : void) : void)

static function all(promises : Array.<Promise.<T>>) : Promise.<Array.<T>>

static function race(promises : Array.<Promise.<T>>) : Promise.<T>

static function cast(x : Promise.<T>) : Promise.<T>

If given value is a promse, then return the value. Otherwise, make a new promise that is fulfilled with the value.

static function cast(x : T) : Promise.<T>

static function reject(reason : variant) : Promise.<T>

static function resolve(result : T) : Promise.<T>

function catch(onRejected : function (:variant) : void) : void

native class Object

The root class of all classes.

new Object()

function toString() : string

Returns a string representing the object.

final native class Function

A class representing a static function. Unlike JavaScript, JSX does not provide Function#call() or Function#apply() since it is a statically-typed language.

final native class String

A wrapper object for primitive strings.

Unless otherwise noted, the defintions of the methods match those specified in ECMA-262, 3rd edition.

__readonly__ var length : int

The length of a string.

new String()

Constructs a String object containing an empty string.

new String(s : string)

Constructs a String object wrapping the given string.

new String(s : String)

Constructs a String object wrapping the value wrapped by the given object.

static function fromCharCode(charN : ...number) : string

Returns a string value containing as many characters as the number of arguments.

override function toString() : string

Returns this string value. (Note that, for a String object, the toString method happens to return the same thing as the valueOf method.)

function valueOf() : string

Returns this string value.

function charAt(pos : number) : string

Returns a string containing the character at position pos in the string resulting from converting this object to a string. If there is no character at that position, the result is the empty string. The result is a string value, not a String object.

function charCodeAt(pos : number) : number

Returns a number (a nonnegative integer less than 216) representing the code point value of the character at position pos in the string resulting from converting this object to a string. If there is no character at that position, the result is NaN.

function concat(stringN : ...string) : string

When the concat method is called with zero or more arguments string1, string2, etc., it returns a string consisting of the characters of this object followed by the characters of each of string1, string2, etc. The result is a string value, not a String object.

function indexOf(searchString : string) : int

If searchString appears as a substring of the result of converting this object to a string then the index of the smallest such position is returned; otherwise, -1 is returned.

function indexOf(searchString : string, position : number) : int

If searchString appears as a substring of the result of converting this object to a string, at one or more positions that are greater than or equal to position, then the index of the smallest such position is returned; otherwise, -1 is returned.

function lastIndexOf(searchString : string) : int

If searchString appears as a substring of the result of converting this object to a string then the index of the greatest such position is returned; otherwise, -1 is returned.

function lastIndexOf(searchString : string, position : number) : int

If searchString appears as a substring of the result of converting this object to a string at one or more positions that are smaller than or equal to position, then the index of the greatest such position is returned; otherwise, -1 is returned.

function localeCompare(that : string) : number

Returns a number indicating whether a reference string comes before or after or is the same as the given string in sort order. Returns a number indicating whether a reference string comes before or after or is the same as the given string in sort order. Returns a negative number if the string occurs earlier in a sort than compareString, returns a positive number if the string occurs afterwards in such a sort, and returns 0 if they occur at the same level.
that The string against which the referring string is comparing.

function match(regexp : RegExp) : Array.<string>

Used to retrieve the matches when matching a string against a regular expression. If the regular expression does not include the g flag, returns the same result as regexp.exec(string). If the regular expression includes the g flag, the method returns an Array containing all matches. If there were no matches, the method returns null. The returned Array has an extra input property, which contains the regexp that generated it as a result. In addition, it has an index property, which represents the zero-based index of the match in the string.
regexp A regular expression object.

function replace(searchValue : string, replaceValue : string) : string

Returns a new string with some or all matches of a pattern replaced by a replacement.

function replace(searchValue : RegExp, replaceValue : string) : string

Returns a new string with some or all matches of a pattern replaced by a replacement.

function replace(searchValue : string, replaceValue : function (:string) : string) : string

Returns a new string with some or all matches of a pattern replaced by a replacement.

function replace(searchValue : RegExp, replaceValue : function (:string) : string) : string

Returns a new string with some or all matches of a pattern replaced by a replacement.

function search(searchValue : string) : int

Executes the search for a match between a regular expression and this String object.

function search(searchValue : RegExp) : int

Executes the search for a match between a regular expression and this String object.

function slice(start : number) : string

Extracts a section of a string and returns a new string.
start The zero-based index at which to begin extraction.

function slice(start : number, end : number) : string

Extracts a section of a string and returns a new string.
start The zero-based index at which to begin extraction.
end The zero-based index at which to end extraction.

function split(separator : string) : Array.<string>

Splits a String object into an array of strings by separating the string into substrings.
separator Specifies the character sequence to use for separating the string.

function split(separator : string, limit : number) : Array.<string>

Splits a String object into an array of strings by separating the string into substrings.
separator Specifies the character sequence to use for separating the string.
limit Integer specifying a limit on the number of splits to be found. The split method still splits on every match of separator, but it truncates the returned array to at most limit elements.

function split(separator : RegExp) : Array.<string>

Splits a String object into an array of strings by separating the string into substrings.
separator Specifies an regular expression to use for separating the string.

function split(separator : RegExp, limit : number) : Array.<string>

Splits a String object into an array of strings by separating the string into substrings.
separator Specifies an regular expression to use for separating the string.
limit Integer specifying a limit on the number of splits to be found. The split method still splits on every match of separator, but it truncates the returned array to at most limit elements.

function substring(start : number) : string

Returns a subset of a string starting at the given offset.
start The zero-based index at which to begin extraction.

function substring(start : number, end : number) : string

Returns a subset of a string starting at the given offset.
start The zero-based index at which to begin extraction.
end The zero-based index at which to end extraction.

function toLowerCase() : string

Returns the calling string value converted to lowercase.

function toLocaleLowerCase() : string

Returns the calling string value converted to lowercase.

function toUpperCase() : string

Returns the calling string value converted to uppercase.

function toLocaleUpperCase() : string

Returns the calling string value converted to uppercase.

function trim() : string

Removes whitespace from both ends of the string.

static function encodeURIComponent(str : string) : string

Encodes a Uniform Resource Identifier (URI) component by replacing each instance of certain characters by one, two, three, or four escape sequences representing the UTF-8 encoding of the character.
str A component of a URI.

static function decodeURIComponent(encodedURI : string) : string

Decodes a Uniform Resource Identifier (URI) component previously created by encodeURIComponent or by a similar routine.
encodedURI An encoded component of a Uniform Resource Identifier.

static function encodeURI(str : string) : string

Encodes a Uniform Resource Identifier (URI) by replacing each instance of certain characters by one, two, three, or four escape sequences representing the UTF-8 encoding of the character.
str A complete Uniform Resource Identifier.

static function decodeURI(encodedURI : string) : string

Decodes a Uniform Resource Identifier (URI) previously created by encodeURI or by a similar routine.
encodedURI A complete, encoded Uniform Resuorce Identifier.

final native class Boolean

A wrapper object for primitive booleans.

new Boolean()

Constructs a Boolean object containing a false.

new Boolean(value : boolean)

Constructs a Boolean object wrapping the given value.

new Boolean(value : Boolean)

Constructs a Boolean object wrapping the value wrapped by the given object.

override function toString() : string

Returns a string of either "true" or "false" depending upon the value of the object.

function valueOf() : boolean

Returns the wrapped boolean value.

final native class Number

A wrapper object for primitive numbers.

static const var MAX_VALUE : number

The maximum numeric value representable.

static const var MIN_VALUE : number

The minimum numeric value representable.

new Number()

Constructs a Number object containing 0.0.

new Number(value : number)

Constructs a Number object wrapping the given value.

new Number(value : Number)

Constructs a Number object wrapping the value wrapped by the given object.

override function toString() : string

Returns a string representing the number.

function toString(radix : number) : string

Returns a string representing the number.
radix An integer between 2 and 36 specifying the base to use for representing numeric values.

function toLocaleString() : string

This method available to numbers will convert the number into a string which is suitable for presentation in the given locale.

function valueOf() : number

Returns the wrapped number value.

function toFixed(fractionDigits : number) : string

Formats a number using fixed-point notation.

function toExponential(fractionDigits : number) : string

Returns a string representing the Number object in exponential notation.

function toPrecision(precision : number) : string

Returns a string representing the Number object to the specified precision.

static function parseInt(str : string) : number

Parses a string argument and returns an integer if successful, or NaN if failed.
str The value to parse. Leading whitespace in the string is ignored.

static function parseInt(str : string, radix : number) : number

Parses a string argument and returns an integer if successful, or NaN if failed.
str The value to parse. Leading whitespace in the string is ignored.
radix An integer that represents the radix of the above mentioned string.

static function parseFloat(str : string) : number

Parses a string argument and returns a floating point number.

If it encounters a character other than a sign (+ or -), numeral (0-9), a decimal point, or an exponent, it returns the value up to that point and ignores that character and all succeeding characters. Leading and trailing spaces are allowed.

If the first character cannot be converted to a number, parseFloat returns NaN.

static function isNaN(num : number) : boolean

Determines whether a number is NaN or not.

static function isFinite(num : number) : boolean

Determines whether a number is finite or not.

final native class Math

Provides mathmetical constants and functions.

Unless otherwise noted, the defintions of the methods match those specified in ECMA-262, 3rd edition.

static const var E : number

Euler's constant and the base of natural logarithms, approximately 2.718.

static const var LN10 : number

Natural logarithm of 10, approximately 2.302.

static const var LN2 : number

Natural logarithm of 2, approximately 0.693.

static const var LOG2E : number

Base 2 logarithm of E, approximately 1.442.

static const var LOG10E : number

Base 10 logarithm of E, approximately 0.434.

static const var PI : number

Ratio of the circumference of a circle to its diameter, approximately 3.14159.

static const var SQRT1_2 : number

Square root of 1/2; equivalently, 1 over the square root of 2, approximately 0.707.

static const var SQRT2 : number

Square root of 2, approximately 1.414.

static function abs(x : number) : number

Returns the absolute value of a number.

static function acos(x : number) : number

static function asin(x : number) : number

static function atan(x : number) : number

static function atan2(y : number, x : number) : number

static function ceil(x : number) : number

static function cos(x : number) : number

static function exp(x : number) : number

static function floor(x : number) : number

static function log(x : number) : number

static function max(value1 : number, value2 : number, value3 : number, valueN : ...number) : number

static function max(value1 : number) : number

static function min(value1 : number, value2 : number, value3 : number, valueN : ...number) : number

static function min(value1 : number) : number

static function pow(x : number, y : number) : number

static function random() : number

static function round(x : number) : number

static function sin(x : number) : number

static function sqrt(x : number) : number

static function tan(x : number) : number

static function max(value1 : number, value2 : number) : number

static function min(value1 : number, value2 : number) : number

final native class Date

An object for working with dates and times.

Unless otherwise noted, the defintions of the methods match those specified in ECMA-262, 3rd edition.

new Date(year : number, month : number)

Creates a Date object.

new Date(year : number, month : number, date : number)

Creates a Date object.

new Date(year : number, month : number, date : number, hours : number)

Creates a Date object.

new Date(year : number, month : number, date : number, hours : number, minutes : number)

Creates a Date object.

new Date(year : number, month : number, date : number, hours : number, minutes : number, seconds : number)

Creates a Date object.

new Date(year : number, month : number, date : number, hours : number, minutes : number, seconds : number, ms : number)

Creates a Date object.

new Date(value : string)

Creates a Date object.
value String value representing a date. The string should be in a format recognized by the parse method (IETF-compliant RFC 2822 timestamps).

new Date(value : number)

Creates a Date object.
value Integer value representing the number of milliseconds since 1 January 1970 00:00:00 UTC (Unix Epoch).

new Date(value : Date)

Clones the given object.

new Date()

Creates a Date object for today's date and time according to local time.

static function parse(value : string) : number

static function UTC(year : number, month : number) : number

static function UTC(year : number, month : number, date : number) : number

static function UTC(year : number, month : number, date : number, hours : number) : number

static function UTC(year : number, month : number, date : number, hours : number, minutes : number) : number

static function UTC(year : number, month : number, date : number, hours : number, minutes : number, seconds : number) : number

static function UTC(year : number, month : number, date : number, hours : number, minutes : number, seconds : number, ms : number) : number

static function now() : number

override function toString() : string

function toDateString() : string

function toTimeString() : string

function toLocaleString() : string

function toLocaleDateString() : string

function toLocaleTimeString() : string

function valueOf() : number

function getTime() : number

function getFullYear() : number

function getUTCFullYear() : number

function getMonth() : number

function getUTCMonth() : number

function getDate() : number

function getUTCDate() : number

function getDay() : number

function getUTCDay() : number

function getHours() : number

function getUTCHours() : number

function getMinutes() : number

function getUTCMinutes() : number

function getSeconds() : number

function getUTCSeconds() : number

function getMilliseconds() : number

function getUTCMilliseconds() : number

function getTimezoneOffset() : number

function setTime(time : number) : number

function setMilliseconds(ms : number) : number

function setUTCMilliseconds(ms : number) : number

function setSeconds(sec : number) : number

function setUTCSeconds(sec : number) : number

function setMinutes(min : number) : number

function setUTCMinutes(min : number) : number

function setHours(hour : number) : number

function setUTCHours(hour : number) : number

function setDate(date : number) : number

function setUTCDate(date : number) : number

function setMonth(month : number) : number

function setUTCMonth(month : number) : number

function setFullYear(year : number) : number

function setUTCFullYear(year : number) : number

function toUTCString() : string

function toISOString() : string

function toJSON() : string

function toJSON(key : string) : string

final native class RegExp

An object that represents a regular-expression.

Unless otherwise noted, the defintions of the methods match those specified in ECMA-262, 3rd edition.

__readonly__ var source : string

__readonly__ var global : boolean

__readonly__ var ignoreCase : boolean

__readonly__ var multiline : boolean

__readonly__ var lastIndex : int

new RegExp(pattern : string, flags : string)

new RegExp(pattern : string)

new RegExp(pattern : RegExp)

function exec(str : string) : Array.<string>

function test(str : string) : boolean

override function toString() : string

native class Error

var name : string

var message : string

var stack : string

Implementation-dependent stack trace information

new Error()

new Error(message : string)

native class EvalError extends Error

new EvalError()

new EvalError(message : string)

native class RangeError extends Error

new RangeError()

new RangeError(message : string)

native class ReferenceError extends Error

new ReferenceError()

new ReferenceError(message : string)

native class SyntaxError extends Error

new SyntaxError()

new SyntaxError(message : string)

native class TypeError extends Error

new TypeError()

new TypeError(message : string)

final native class GeneratorFunction

final native class JSON

Provides static functions to manipulate JSON.

Unless otherwise noted, the defintions of the methods match those specified in ECMA-262, 5th edition.

static function parse(text : string) : variant

static function parse(text : string, reviver : function (:string, :variant) : variant) : variant

static function stringify(value : variant) : string

static function stringify(value : variant, replacer : function (:string, :variant) : variant) : string

static function stringify(value : variant, replacer : function (:string, :variant) : variant, space : number) : string

static function stringify(value : variant, replacer : function (:string, :variant) : variant, space : string) : string

native class Transferable

new Transferable()

final native class ArrayBuffer extends Transferable

__readonly__ var byteLength : number

new ArrayBuffer(length : number)

function slice(begin : number) : ArrayBuffer

function slice(begin : number, end : number) : ArrayBuffer

native class ArrayBufferView

__readonly__ var buffer : ArrayBuffer

__readonly__ var byteOffset : number

__readonly__ var byteLength : number

new ArrayBufferView()

final native class Int8Array extends ArrayBufferView

static __readonly__ var BYTES_PER_ELEMENT : number

__readonly__ var BYTES_PER_ELEMENT : number

__readonly__ var length : number

new Int8Array(length : number)

new Int8Array(array : Int8Array)

new Int8Array(array : Array.<number>)

new Int8Array(array : Array.<int>)

new Int8Array(buffer : ArrayBuffer)

new Int8Array(buffer : ArrayBuffer, byteOffset : number)

new Int8Array(buffer : ArrayBuffer, byteOffset : number, length : number)

function get(index : number) : Nullable.<number>

function set(index : number, value : number) : void

function set(array : Int8Array) : void

function set(array : Int8Array, offset : number) : void

function set(array : Array.<number>) : void

function set(array : Array.<number>, offset : number) : void

function set(array : Array.<int>) : void

function set(array : Array.<int>, offset : number) : void

function subarray(start : number, end : number) : Int8Array

native class Uint8Array extends ArrayBufferView

static __readonly__ var BYTES_PER_ELEMENT : number

__readonly__ var BYTES_PER_ELEMENT : number

__readonly__ var length : number

new Uint8Array(length : number)

new Uint8Array(array : Uint8Array)

new Uint8Array(array : Array.<number>)

new Uint8Array(array : Array.<int>)

new Uint8Array(buffer : ArrayBuffer)

new Uint8Array(buffer : ArrayBuffer, byteOffset : number)

new Uint8Array(buffer : ArrayBuffer, byteOffset : number, length : number)

function get(index : number) : Nullable.<number>

function set(index : number, value : number) : void

function set(array : Uint8Array) : void

function set(array : Uint8Array, offset : number) : void

function set(array : Array.<number>) : void

function set(array : Array.<number>, offset : number) : void

function set(array : Array.<int>) : void

function set(array : Array.<int>, offset : number) : void

function subarray(start : number, end : number) : Uint8Array

final native class Uint8ClampedArray extends Uint8Array

new Uint8ClampedArray(length : number)

new Uint8ClampedArray(array : Uint8ClampedArray)

new Uint8ClampedArray(array : Uint8Array)

new Uint8ClampedArray(array : Array.<number>)

new Uint8ClampedArray(array : Array.<int>)

new Uint8ClampedArray(buffer : ArrayBuffer)

new Uint8ClampedArray(buffer : ArrayBuffer, byteOffset : number)

new Uint8ClampedArray(buffer : ArrayBuffer, byteOffset : number, length : number)

function set(array : Uint8ClampedArray) : void

function set(array : Uint8ClampedArray, offset : number) : void

override function subarray(start : number, end : number) : Uint8ClampedArray

final native class Int16Array extends ArrayBufferView

static __readonly__ var BYTES_PER_ELEMENT : number

__readonly__ var BYTES_PER_ELEMENT : number

__readonly__ var length : number

new Int16Array(length : number)

new Int16Array(array : Int16Array)

new Int16Array(array : Array.<number>)

new Int16Array(array : Array.<int>)

new Int16Array(buffer : ArrayBuffer)

new Int16Array(buffer : ArrayBuffer, byteOffset : number)

new Int16Array(buffer : ArrayBuffer, byteOffset : number, length : number)

function get(index : number) : Nullable.<number>

function set(index : number, value : number) : void

function set(array : Int16Array) : void

function set(array : Int16Array, offset : number) : void

function set(array : Array.<number>) : void

function set(array : Array.<number>, offset : number) : void

function set(array : Array.<int>) : void

function set(array : Array.<int>, offset : number) : void

function subarray(start : number, end : number) : Int16Array

final native class Uint16Array extends ArrayBufferView

static __readonly__ var BYTES_PER_ELEMENT : number

__readonly__ var BYTES_PER_ELEMENT : number

__readonly__ var length : number

new Uint16Array(length : number)

new Uint16Array(array : Uint16Array)

new Uint16Array(array : Array.<number>)

new Uint16Array(array : Array.<int>)

new Uint16Array(buffer : ArrayBuffer)

new Uint16Array(buffer : ArrayBuffer, byteOffset : number)

new Uint16Array(buffer : ArrayBuffer, byteOffset : number, length : number)

function get(index : number) : Nullable.<number>

function set(index : number, value : number) : void

function set(array : Uint16Array) : void

function set(array : Uint16Array, offset : number) : void

function set(array : Array.<number>) : void

function set(array : Array.<number>, offset : number) : void

function set(array : Array.<int>) : void

function set(array : Array.<int>, offset : number) : void

function subarray(start : number, end : number) : Uint16Array

final native class Int32Array extends ArrayBufferView

static __readonly__ var BYTES_PER_ELEMENT : number

__readonly__ var BYTES_PER_ELEMENT : number

__readonly__ var length : number

new Int32Array(length : number)

new Int32Array(array : Int32Array)

new Int32Array(array : Array.<number>)

new Int32Array(array : Array.<int>)

new Int32Array(buffer : ArrayBuffer)

new Int32Array(buffer : ArrayBuffer, byteOffset : number)

new Int32Array(buffer : ArrayBuffer, byteOffset : number, length : number)

function get(index : number) : Nullable.<number>

function set(index : number, value : number) : void

function set(array : Int32Array) : void

function set(array : Int32Array, offset : number) : void

function set(array : Array.<number>) : void

function set(array : Array.<number>, offset : number) : void

function set(array : Array.<int>) : void

function set(array : Array.<int>, offset : number) : void

function subarray(start : number, end : number) : Int32Array

final native class Uint32Array extends ArrayBufferView

static __readonly__ var BYTES_PER_ELEMENT : number

__readonly__ var BYTES_PER_ELEMENT : number

__readonly__ var length : number

new Uint32Array(length : number)

new Uint32Array(array : Uint32Array)

new Uint32Array(array : Array.<number>)

new Uint32Array(array : Array.<int>)

new Uint32Array(buffer : ArrayBuffer)

new Uint32Array(buffer : ArrayBuffer, byteOffset : number)

new Uint32Array(buffer : ArrayBuffer, byteOffset : number, length : number)

function get(index : number) : Nullable.<number>

function set(index : number, value : number) : void

function set(array : Uint32Array) : void

function set(array : Uint32Array, offset : number) : void

function set(array : Array.<number>) : void

function set(array : Array.<number>, offset : number) : void

function set(array : Array.<int>) : void

function set(array : Array.<int>, offset : number) : void

function subarray(start : number, end : number) : Uint32Array

final native class Float32Array extends ArrayBufferView

static __readonly__ var BYTES_PER_ELEMENT : number

__readonly__ var BYTES_PER_ELEMENT : number

__readonly__ var length : number

new Float32Array(length : number)

new Float32Array(array : Float32Array)

new Float32Array(array : Array.<number>)

new Float32Array(array : Array.<int>)

new Float32Array(buffer : ArrayBuffer)

new Float32Array(buffer : ArrayBuffer, byteOffset : number)

new Float32Array(buffer : ArrayBuffer, byteOffset : number, length : number)

function get(index : number) : Nullable.<number>

function set(index : number, value : number) : void

function set(array : Float32Array) : void

function set(array : Float32Array, offset : number) : void

function set(array : Array.<number>) : void

function set(array : Array.<number>, offset : number) : void

function set(array : Array.<int>) : void

function set(array : Array.<int>, offset : number) : void

function subarray(start : number, end : number) : Float32Array

final native class Float64Array extends ArrayBufferView

static __readonly__ var BYTES_PER_ELEMENT : number

__readonly__ var BYTES_PER_ELEMENT : number

__readonly__ var length : number

new Float64Array(length : number)

new Float64Array(array : Float64Array)

new Float64Array(array : Array.<number>)

new Float64Array(array : Array.<int>)

new Float64Array(buffer : ArrayBuffer)

new Float64Array(buffer : ArrayBuffer, byteOffset : number)

new Float64Array(buffer : ArrayBuffer, byteOffset : number, length : number)

function get(index : number) : Nullable.<number>

function set(index : number, value : number) : void

function set(array : Float64Array) : void

function set(array : Float64Array, offset : number) : void

function set(array : Array.<number>) : void

function set(array : Array.<number>, offset : number) : void

function set(array : Array.<int>) : void

function set(array : Array.<int>, offset : number) : void

function subarray(start : number, end : number) : Float64Array

final native class DataView extends ArrayBufferView

new DataView(buffer : ArrayBuffer)

new DataView(buffer : ArrayBuffer, byteOffset : number)

new DataView(buffer : ArrayBuffer, byteOffset : number, byteLength : number)

function getInt8(byteOffset : number) : number

function getUint8(byteOffset : number) : number

function getInt16(byteOffset : number) : number

function getInt16(byteOffset : number, littleEndian : boolean) : number

function getUint16(byteOffset : number) : number

function getUint16(byteOffset : number, littleEndian : boolean) : number

function getInt32(byteOffset : number) : number

function getInt32(byteOffset : number, littleEndian : boolean) : number

function getUint32(byteOffset : number) : number

function getUint32(byteOffset : number, littleEndian : boolean) : number

function getFloat32(byteOffset : number) : number

function getFloat32(byteOffset : number, littleEndian : boolean) : number

function getFloat64(byteOffset : number) : number

function getFloat64(byteOffset : number, littleEndian : boolean) : number

function setInt8(byteOffset : number, value : number) : void

function setUint8(byteOffset : number, value : number) : void

function setInt16(byteOffset : number, value : number) : void

function setInt16(byteOffset : number, value : number, littleEndian : boolean) : void

function setUint16(byteOffset : number, value : number) : void

function setUint16(byteOffset : number, value : number, littleEndian : boolean) : void

function setInt32(byteOffset : number, value : number) : void

function setInt32(byteOffset : number, value : number, littleEndian : boolean) : void

function setUint32(byteOffset : number, value : number) : void

function setUint32(byteOffset : number, value : number, littleEndian : boolean) : void

function setFloat32(byteOffset : number, value : number) : void

function setFloat32(byteOffset : number, value : number, littleEndian : boolean) : void

function setFloat64(byteOffset : number, value : number) : void

function setFloat64(byteOffset : number, value : number, littleEndian : boolean) : void

final native class JSX

Provides static functions to control the behaviour of the JSX runtime.

static const var DEBUG : boolean

A flag which is disabled by --optimize no-debug.
This is intended to remove debugging statements on release build.

static const var ENV : Map.<string>

List of compile-time constants passed in by jsx --define name=var

static function profilerIsRunning() : boolean

Returns whether or not the profiler is running. The profiler is enabled by --profile option. @ see http://jsx.github.io/doc/profiler.html

static function getProfileResults() : variant

Returns the profiler results. @ see http://jsx.github.io/doc/profiler.html

static function postProfileResults(url : string) : void

Posts the profiler results to the given URL. @ see http://jsx.github.io/doc/profiler.html

static function postProfileResults(url : string, cb : function (:Error, :string) : void) : void

static function resetProfileResults() : void

Resets the collected profiler results. @ see http://jsx.github.io/doc/profiler.html