Apache Flex 4.16.1 API Reference | All Packages | All Classes | Index | Frames No Frames |
DeferredCreationPolicy

Package | spark.containers.supportClasses
Class | public class DeferredCreationPolicy
Inheritance | DeferredCreationPolicy Object

Language Version : | ActionScript 3.0

Product Version : | Flex 4

Runtime Versions : | Flash Player 10, AIR 1.5

| This class is experimental, which means it has not been tested or documented as thoroughly as other core Apache Flex classes.

The DeferredCreationPolicy class defines the constant values for the `creationPolicy` property of the DeferedGroup class.

See also

spark.containers.DeferredGroup.creationPolicy

Public Methods

| Method | Defined By
--- | --- | ---
|  | DeferredCreationPolicy() Constructor | DeferredCreationPolicy

Public Constants

| Constant | Defined By
--- | --- | ---
|  | ALL : String = all [static] Immediately create all descendants. | DeferredCreationPolicy
|  | CONSTRUCT : String = construct [static] Construct all decendants immediately but only inialize those that are visible. | DeferredCreationPolicy
|  | NONE : String = none [static] Do not create any children. | DeferredCreationPolicy
|  | VISIBLE : String = visible [static] Only construct the immediate descendants and initialize those that are visible. | DeferredCreationPolicy

Constructor Detail

DeferredCreationPolicy | () | Constructor

`public function DeferredCreationPolicy()`

Language Version : | ActionScript 3.0

Product Version : | Flex 3

Runtime Versions : | Flash Player 9, AIR 1.1

Constructor

Constant Detail

ALL | Constant

`public static const ALL:String = all`

Language Version : | ActionScript 3.0

Product Version : | Flex 3

Runtime Versions : | Flash Player 9, AIR 1.1

Immediately create all descendants.

Avoid using this `creationPolicy` because it increases the startup time of your application. There is usually no good reason to create components at startup which the user cannot see. If you are using this policy so that you can "push" data into hidden components at startup, you should instead design your application so that the data is stored in data variables and components which are created later "pull" in this data, via databinding or an `initialize` handler.

CONSTRUCT | Constant |

`public static const CONSTRUCT:String = construct`

Language Version : | ActionScript 3.0

Product Version : | Flex 3

Runtime Versions : | Flash Player 9, AIR 1.1

Construct all decendants immediately but only inialize those that are visible.

This is useful if you using the container as a dataProvider to a MenuBar, as the MenuBar requires all the children to be created to get the correct dataProvider to drive its content.

NONE | Constant |

`public static const NONE:String = none`

Language Version : | ActionScript 3.0

Product Version : | Flex 3

Runtime Versions : | Flash Player 9, AIR 1.1

Do not create any children.

With this `creationPolicy`, it is the developer's responsibility to programmatically create the children from the UIComponentDescriptors by calling `createComponentsFromDescriptors()` on the parent container.

VISIBLE | Constant |

`public static const VISIBLE:String = visible`

Language Version : | ActionScript 3.0

Product Version : | Flex 3

Runtime Versions : | Flash Player 9, AIR 1.1

Only construct the immediate descendants and initialize those that are visible.

Wed Nov 15 2017, 09:50 AM +01:00