Class ClassManager

Index

Methods

Methods

public static addNameAliasMappings(aliases?: any): IClassManager

[Method] Adds a batch of class name to alias mappings

Parameters

  • aliases?: any optional

    Object The set of mappings of the form className : [values...]

Returns

IClassManager

Ext.ClassManager this

public static addNameAlternateMappings(alternates?: any): IClassManager

[Method]

Parameters

  • alternates?: any optional

    Object The set of mappings of the form className : [values...]

Returns

IClassManager

Ext.ClassManager this

public static get(name?: string): IClass

[Method] Retrieve a class by its name

Parameters

  • name?: string optional

    String

Returns

IClass

Ext.Class class

public static getAliasesByName(name?: string): Array<any>

[Method] Get the aliases of a class by the class name

Parameters

  • name?: string optional

    String

Returns

Array<any>

Array aliases

public static getByAlias(alias?: string): IClass

[Method] Get a reference to the class by its alias

Parameters

  • alias?: string optional

    String

Returns

IClass

Ext.Class class

public static getClass(object?: any): IClass

[Method] Get the class of the provided object returns null if it s not an instance of any class created with Ext define

Parameters

  • object?: any optional

    Object

Returns

IClass

Ext.Class class

public static getName(object?: any): string

[Method] Get the name of the class by its reference or its instance usually invoked by the shorthand Ext getClassName Ext Cl

Parameters

  • object?: any optional

    Ext.Class/Object

Returns

string

String className

public static getNameByAlias(alias?: string): string

[Method] Get the name of a class by its alias

Parameters

  • alias?: string optional

    String

Returns

string

String className

public static getNameByAlternate(alternate?: string): string

[Method] Get the name of a class by its alternate name

Parameters

  • alternate?: string optional

    String

Returns

string

String className

public static getNamesByExpression(expression?: string): Array<any>

[Method] Converts a string expression to an array of matching class names

Parameters

  • expression?: string optional

    String

Returns

Array<any>

Array classNames

public static instantiate(name?: string, args?: any): any

[Method] Instantiate a class by either full name alias or alternate name usually invoked by the convenient shorthand Ext cre

Parameters

  • name?: string optional

    String

  • args?: any optional

    Mixed Additional arguments after the name will be passed to the class' constructor.

Returns

any

Object instance

public static instantiateByAlias(alias: string, args?: Array<any>): any

[Method] Instantiate a class by its alias usually invoked by the convenient shorthand Ext createByAlias If Ext Loader is enab

Parameters

  • alias: string

    String

  • args?: Array<any> optional

    Mixed... Additional arguments after the alias will be passed to the class constructor.

Returns

any

Object instance

public static isCreated(className?: string): boolean

[Method] Checks if a class has already been created

Parameters

  • className?: string optional

    String

Returns

boolean

Boolean exist

public static set(name?: string, value?: any): IClassManager

[Method] Sets a name reference to a class

Parameters

  • name?: string optional

    String

  • value?: any optional

    Object

Returns

IClassManager

Ext.ClassManager this

public static setAlias(cls?: any, alias?: string): IClassManager

[Method] Register the alias for a class

Parameters

  • cls?: any optional

    Ext.Class/String a reference to a class or a className.

  • alias?: string optional

    String Alias to use when referring to this class.

Returns

IClassManager

Ext.ClassManager this

public static setNamespace(name?: string, value?: any)

[Method] Creates a namespace and assign the value to the created object

Parameters

  • name?: string optional

    String

  • value?: any optional

    Mixed