Main Page | Packages | Class Tree | Index | Help

xp.system

class ClassLoader

MovieClip
  |
  +--xp.system.ClassLoader


class ClassLoader
extends MovieClip

ClassLoader
Creates new class instances for classes that extend movieclip. Also creates non-class based MovieClips.


Author:
ProWin Computers Ltd. - Rob Edgar

Version:
3.0.0.000

See also:


Method Summary

public static
classForName ( className )
Returns the Class object associated with the class or interface with the given string name

public static
createClassInstance ( owner: Object, classObject, instanceId: String, depth: Number, initobj: Object ): Object
Creates a new instance of a class that extends movieclip

public static
createObjectInstance ( owner: Object, linkageName: String, instanceId: String, depth: Number, initobj: Object ): MovieClip
Creates a new instance of a movieclip



Method Documentation

classForName

public static function classForName(className)
Returns the Class object associated with the class or interface with the given string name

Usage:
For example, the following code fragment returns the runtime Class descriptor for the class named xp.controls.TextInput: var t = ClassLoader.classForName("xp.controls.TextInput")

Parameters:
className
- the fully qualified name of the desired class.
Returns:
the Class object for the class with the specified name

createClassInstance

public static function createClassInstance(owner: Object,
 classObject,
 instanceId: String,
 depth: Number,
 initobj: Object): Object
Creates a new instance of a class that extends movieclip

Parameters:
owner
the parent movieclip that this instance will be attached to
classObject
the Class object to be instantiated, classObject is untyped so as to allow strings or classes to be passed in
instanceId
(Optional)A unique instance Id or name for the class being instantiated
depth
(Optional)The depth that this instance will be created at
initobj
initObj (Optional)Initialization properties that will be passed to the class when it is instantiated
Returns:
A reference to the newly created instance

createObjectInstance

public static function createObjectInstance(owner: Object,
 linkageName: String,
 instanceId: String,
 depth: Number,
 initobj: Object): MovieClip
Creates a new instance of a movieclip

Takes a symbol from the library and attaches it to the SWF file on the Stage specified by owner.

Parameters:
owner
The parent movieclip that this instance will be attached to
linkageName
The linkage name of the movie clip symbol in the library to attach to a movie clip on the Stage. This is the name entered in the Identifier field in the Linkage Properties dialog box
instanceId
A unique instance Id or name for the movie clip being attached to the movie clip
depth
An integer specifying the depth level where the SWF file is placed
initobj
initObj An object containing properties with which to populate the newly attached movie clip. This parameter allows dynamically created movie clips to receive clip parameters. If initObject is not an object, it is ignored. All properties of initObject are copied into the new instance. The properties specified with initObject are available to the constructor function.
Returns:
A reference to the newly created instance


The documentation was generated from the following file:


Generated on 10/30/2005 9:34:02 PM by AS2Doc