C# Class Jurassic.Library.FunctionInstance

Represents a JavaScript function.
Inheritance: ObjectInstance
Afficher le fichier Open project: paulbartrum/jurassic Class Usage Examples

Méthodes publiques

Méthode Description
CallLateBound ( object thisObject ) : object

Calls this function, passing in the given "this" value and zero or more arguments.

CallWithStackTrace ( string path, string function, int line, object thisObject, object argumentValues ) : object

Calls this function, passing in the given "this" value and zero or more arguments.

ConstructLateBound ( ) : ObjectInstance

Creates an object, using this function as the constructor.

HasInstance ( object instance ) : bool

Determines whether the given object inherits from this function. More precisely, it checks whether the prototype chain of the object contains the prototype property of this function. Used by the "instanceof" operator.

ToString ( ) : string

Returns a string representing this object.

Méthodes protégées

Méthode Description
FunctionInstance ( ObjectInstance prototype ) : System

Creates a new instance of a built-in function object.

FunctionInstance ( ScriptEngine engine ) : System

Creates a new instance of a built-in function object, with the default Function prototype.

FunctionInstance ( ScriptEngine engine, ObjectInstance prototype ) : System

Creates a new instance of a built-in function object.

Private Methods

Méthode Description
Apply ( object thisObj, object arguments ) : object
Bind ( object boundThis ) : FunctionInstance
Call ( object thisObj ) : object
CallFromNative ( string function, object thisObject ) : object

Calls this function, passing in the given "this" value and zero or more arguments.

GetDeclarativeProperties ( ScriptEngine engine ) : List
InitializePrototypeProperties ( ObjectInstance obj, FunctionConstructor constructor ) : void

Initializes the prototype properties.

ToStringJS ( ) : string
__STUB__Apply ( ScriptEngine engine, object thisObj, object args ) : object
__STUB__Bind ( ScriptEngine engine, object thisObj, object args ) : object
__STUB__Call ( ScriptEngine engine, object thisObj, object args ) : object
__STUB__ToStringJS ( ScriptEngine engine, object thisObj, object args ) : object

Method Details

CallLateBound() public abstract méthode

Calls this function, passing in the given "this" value and zero or more arguments.
public abstract CallLateBound ( object thisObject ) : object
thisObject object The value of the "this" keyword within the function.
Résultat object

CallWithStackTrace() public méthode

Calls this function, passing in the given "this" value and zero or more arguments.
public CallWithStackTrace ( string path, string function, int line, object thisObject, object argumentValues ) : object
path string The path of the javascript source file that contains the caller.
function string The name of the caller function.
line int The line number of the statement that is calling this function.
thisObject object The value of the "this" keyword within the function.
argumentValues object An array of argument values.
Résultat object

ConstructLateBound() public méthode

Creates an object, using this function as the constructor.
public ConstructLateBound ( ) : ObjectInstance
Résultat ObjectInstance

FunctionInstance() protected méthode

Creates a new instance of a built-in function object.
protected FunctionInstance ( ObjectInstance prototype ) : System
prototype ObjectInstance The next object in the prototype chain.
Résultat System

FunctionInstance() protected méthode

Creates a new instance of a built-in function object, with the default Function prototype.
protected FunctionInstance ( ScriptEngine engine ) : System
engine ScriptEngine The associated script engine.
Résultat System

FunctionInstance() protected méthode

Creates a new instance of a built-in function object.
protected FunctionInstance ( ScriptEngine engine, ObjectInstance prototype ) : System
engine ScriptEngine The associated script engine.
prototype ObjectInstance The next object in the prototype chain. Can be null.
Résultat System

HasInstance() public méthode

Determines whether the given object inherits from this function. More precisely, it checks whether the prototype chain of the object contains the prototype property of this function. Used by the "instanceof" operator.
public HasInstance ( object instance ) : bool
instance object The instance to check.
Résultat bool

ToString() public méthode

Returns a string representing this object.
public ToString ( ) : string
Résultat string