
Function.prototype Property
This is the Title of the Book, eMatter Edition
Copyright © 2007 O’Reilly & Associates, Inc. All rights reserved.
532
|
ActionScript Language Reference
Arguments
thisObj The object on which theFunction is called as a method.
param1, ...paramn
A list of values passed as arguments to
theFunction.
Returns
The return value of theFunction.
Description
The call( ) method invokes theFunction as a method of thisObj, and passes the values of
param1, param2, ...paramn to theFunction as arguments. It is functionally identical to the
apply( ) method, except that it specifies arguments to
theFunction as a comma-delimited
list, rather than as an array. For complete details, see Function.apply( ).
Example
function moveClipTo (newX, newY) {
this._x = newX;
this._y = newY;
}
moveClipTo.call(ball_mc, 100, 200); // Moves ball_mc to 100, 200
See Also
Function.apply( ), the Arguments object; Chapter 12
Function.prototype Property
an object specifying methods and properties for a class
Flash 5
read/write
theFunction.prototype
Description
The prototype property is the centerpiece of ActionScript’s class and object inheritance
system. By default, it is a generic object waiting to be assigned properties and methods that
will become available to objects constructed by
theFunction. Like any generic object,
theFunction.prototype starts off with the built-in properties __proto__ and constructor.
ActionScript automatically ...