Class: ScopeArray

sort/scope. ScopeArray

Array that implements Scope for weakly referenced scoped instance variables.


new ScopeArray()

Implements:

Extends

  • Array

Methods


delete(key)

Parameters:
Name Type Description
key *

Reference key of scoped variable.

Implements:
Returns:

successful - Is true if removed, false if element does not exist.

Type
boolean

get(key)

Parameters:
Name Type Description
key *

Reference key of scoped variable.

Implements:
Returns:

value - Scoped variable for the given key or undefined if none exists.

Type
*

has(key)

Parameters:
Name Type Description
key *

Reference key of scoped variable.

Implements:
Returns:

exists - Instance contains a scoped variable for the given key.

Type
boolean

set(key, value)

Parameters:
Name Type Description
key *

Reference key of scoped variable.

value *

Value of scoped variable to set.

Implements:
Returns:
Type
this

slice( [begin] [, end])

Shallow copy a portion of an array into a new array object.

Parameters:
Name Type Argument Default Description
begin number <optional>
0

First index of shallow copy.

end number <optional>
this.length

Last index of shallow copy, not included.

Returns:
Type
Array