Packageorg.axiis.core
Classpublic class AbstractLayout
InheritanceAbstractLayout Inheritance flash.events.EventDispatcher
Subclasses BaseLayout

AbstractLayout is an base class that provides definitions of properties and stubs for methods required by BaseLayout. It is up to the subclass to appropriately override these implementations.



Public Properties
 PropertyDefined By
  bounds : Rectangle
A rectangle that acts as the bounding area for this layout
AbstractLayout
  childSprites : Array
[read-only] The AxiisSprites this layout has created to render each item in its dataProvider.
AbstractLayout
  currentDatum : *
[read-only] The item in the dataProvider that the layout is currently rendering.
AbstractLayout
  currentIndex : int
[read-only] The index of the item in the dataProvider that the layout is currently rendering.
AbstractLayout
  currentLabel : String
[read-only] The label of the item in the dataProvider that the layout is currently rendering, as determine by taking currentDatum[labelField], if a labelField is defined.
AbstractLayout
  currentReference : Geometry
[read-only] The geometry that is being used to render the current data item as it appears after the necessary iterations of the referenceRepeater have been executed.
AbstractLayout
  currentValue : *
[read-only] The value of the item in the dataProvider that the layout is currently rendering, as determined by taking currentDatum[dataField], if a dataField is defined.
AbstractLayout
  dataField : Object
The property within each item in the dataProvider that contains the field used to determine the value of the item.
AbstractLayout
  dataFilterFunction : Function
This provides a way to further refine a layouts dataProvider by providing access to a custom filter data filter function.
AbstractLayout
  dataFilterIndex : Number
[read-only]
AbstractLayout
  dataItems : Array
[read-only] An array of objects extracted from the dataProvider.
AbstractLayout
  dataProvider : Object
An Array, ArrayCollection, or Object containing the data this layout should render.
AbstractLayout
  dataTipAnchorPoint : Object
An Object with x and y values used to determine the location of anchored data tips.
AbstractLayout
  dataTipContentClass : IFactory
A ClassFactory that creates the UIComponent that should be used in the data tip for this AxiisSprite.
AbstractLayout
  dataTipContentComponent : UIComponent
A component that gets passed to any data tip.
AbstractLayout
  dataTipLabelFunction : Function
A method used to determine the text that appears in the data tip for an item rendered by this layout.
AbstractLayout
  dataTipManager : IDataTipManager
The IDataTipManager responsible for laying out data tips for children of this layout.
AbstractLayout
  drawingGeometries : Array
An array of geometries that should be drawn for each item in the data provider.
AbstractLayout
  fills : Array
A placeholder for fills used within this layout.
AbstractLayout
  height : Number
The height of the layout.
AbstractLayout
  itemCount : int
[read-only] The number of items in the dataProvider.
AbstractLayout
  labelField : Object
The property within each item in the dataProvider that contains the field used to determine the label for the item.
AbstractLayout
  layouts : Array
The layouts that should be displayed within this layout.
AbstractLayout
  msPerRenderFrame : Number = 50
Determines how long (milliseconds) a layout will spend on a given frame to render X number of datums
AbstractLayout
  name : String
A string used to identify this layout.
AbstractLayout
  palettes : Array
A placeholder for palettes used within this layout.
AbstractLayout
  parentLayout : AbstractLayout
A reference to the layout that contains this layout.
AbstractLayout
  referenceRepeater : GeometryRepeater
A GeometryRepeater that will be applied to the drawingGeometries once for each item in the dataProvider.
AbstractLayout
  rendering : Boolean
[read-only] Whether or not this layout is currently in a render cycle.
AbstractLayout
  showDataTips : Boolean
A flag that indicates to DataCanvas that it should listen for mouse events that signal the need to create a data tip.
AbstractLayout
  states : Array
An array of states that should be applied to this layout.
AbstractLayout
  strokes : Array
A placeholder for strokes used within this layout.
AbstractLayout
  visible : Boolean
Whether or not this layout is visible.
AbstractLayout
  width : Number
The width of the layout.
AbstractLayout
  x : Number
The horizontal position of the top left corner of this layout within its parent.
AbstractLayout
  y : Number
The vertical position of the top left corner of this layout within its parent.
AbstractLayout
Protected Properties
 PropertyDefined By
  sprite : AxiisSprite
The sprite this layout is currently rendering to.
AbstractLayout
Public Methods
 MethodDefined By
  
Constructor.
AbstractLayout
  
getProperty(obj:Object, propertyName:Object):*
Uses ObjectUtils.getProperty(this,obj,propertyName) to get a property on an object.
AbstractLayout
  
getSprite(owner:DataCanvas):Sprite
Returns the Sprite associated with this layout if owner is in fact the owner of this layout.
AbstractLayout
  
invalidate():void
Notifies the DataCanvas that this layout needs to be rendered.
AbstractLayout
  
Iterates over the items in the dataProvider and stores them in dataItems.
AbstractLayout
  
registerOwner(dataCanvas:DataCanvas):void
Registers a DisplayObject as the owner of this layout.
AbstractLayout
  
render(newSprite:AxiisSprite = null):void
Draws this layout to the specified AxiisSprite.
AbstractLayout
Protected Methods
 MethodDefined By
  
Marks all children as deselected.
AbstractLayout
Events
 Event Summary Defined By
  Dispatched when an AxiisSprite is mousedOver.AbstractLayout
Property Detail
boundsproperty
bounds:Rectangle  [read-write]

A rectangle that acts as the bounding area for this layout

This property can be used as the source for data binding.


Implementation
    public function get bounds():Rectangle
    public function set bounds(value:Rectangle):void
childSpritesproperty 
childSprites:Array  [read-only]

The AxiisSprites this layout has created to render each item in its dataProvider.


Implementation
    public function get childSprites():Array
currentDatumproperty 
currentDatum:*  [read-only]

The item in the dataProvider that the layout is currently rendering.

This property can be used as the source for data binding.


Implementation
    public function get currentDatum():*
currentIndexproperty 
currentIndex:int  [read-only]

The index of the item in the dataProvider that the layout is currently rendering.

This property can be used as the source for data binding.


Implementation
    public function get currentIndex():int
currentLabelproperty 
currentLabel:String  [read-only]

The label of the item in the dataProvider that the layout is currently rendering, as determine by taking currentDatum[labelField], if a labelField is defined.

This property can be used as the source for data binding.


Implementation
    public function get currentLabel():String
currentReferenceproperty 
currentReference:Geometry  [read-only]

The geometry that is being used to render the current data item as it appears after the necessary iterations of the referenceRepeater have been executed.

This property can be used as the source for data binding.


Implementation
    public function get currentReference():Geometry
currentValueproperty 
currentValue:*  [read-only]

The value of the item in the dataProvider that the layout is currently rendering, as determined by taking currentDatum[dataField], if a dataField is defined.

This property can be used as the source for data binding.


Implementation
    public function get currentValue():*
dataFieldproperty 
dataField:Object  [read-write]

The property within each item in the dataProvider that contains the field used to determine the value of the item.

This property can be used as the source for data binding.


Implementation
    public function get dataField():Object
    public function set dataField(value:Object):void
dataFilterFunctionproperty 
public var dataFilterFunction:Function

This provides a way to further refine a layouts dataProvider by providing access to a custom filter data filter function. This allows developers to easily visualize subsets of the data without having to change the underlying data structure.

dataFilterIndexproperty 
dataFilterIndex:Number  [read-only]


Implementation
    public function get dataFilterIndex():Number
dataItemsproperty 
dataItems:Array  [read-only]

An array of objects extracted from the dataProvider.

This property can be used as the source for data binding.


Implementation
    public function get dataItems():Array
dataProviderproperty 
dataProvider:Object  [read-write]

An Array, ArrayCollection, or Object containing the data this layout should render.

If this property is Array or ArrayCollection the layout should render each item. If this property is an Object, it should use an array of the object's properties as they are exposed in a for..each loop.

This property can be used as the source for data binding.


Implementation
    public function get dataProvider():Object
    public function set dataProvider(value:Object):void
dataTipAnchorPointproperty 
dataTipAnchorPoint:Object  [read-write]

An Object with x and y values used to determine the location of anchored data tips. By using the currentReference, you can update this value during the render cycle.

This property can be used as the source for data binding.


Implementation
    public function get dataTipAnchorPoint():Object
    public function set dataTipAnchorPoint(value:Object):void
dataTipContentClassproperty 
dataTipContentClass:IFactory  [read-write]

A ClassFactory that creates the UIComponent that should be used in the data tip for this AxiisSprite.

This property can be used as the source for data binding.


Implementation
    public function get dataTipContentClass():IFactory
    public function set dataTipContentClass(value:IFactory):void
dataTipContentComponentproperty 
dataTipContentComponent:UIComponent  [read-write]

A component that gets passed to any data tip.

This property can be used as the source for data binding.


Implementation
    public function get dataTipContentComponent():UIComponent
    public function set dataTipContentComponent(value:UIComponent):void
dataTipLabelFunctionproperty 
dataTipLabelFunction:Function  [read-write]

A method used to determine the text that appears in the data tip for an item rendered by this layout.

This method takes one argument, the item to determine the label for, and returns a String, the text to show in the data tip.

This property can be used as the source for data binding.


Implementation
    public function get dataTipLabelFunction():Function
    public function set dataTipLabelFunction(value:Function):void
dataTipManagerproperty 
dataTipManager:IDataTipManager  [read-write]

The IDataTipManager responsible for laying out data tips for children of this layout.


Implementation
    public function get dataTipManager():IDataTipManager
    public function set dataTipManager(value:IDataTipManager):void
drawingGeometriesproperty 
drawingGeometries:Array  [read-write]

An array of geometries that should be drawn for each item in the data provider. You can modify these items by using GeometryRepeaters and PropertyModifiers.

This property can be used as the source for data binding.


Implementation
    public function get drawingGeometries():Array
    public function set drawingGeometries(value:Array):void

See also

GeometryRepeater
PropertyModifier
fillsproperty 
public var fills:Array

A placeholder for fills used within this layout. Modifying this array will not have any effect on the rendering of the layout.

This property can be used as the source for data binding.

heightproperty 
height:Number  [read-write]

The height of the layout.

This property can be used as the source for data binding.


Implementation
    public function get height():Number
    public function set height(value:Number):void
itemCountproperty 
itemCount:int  [read-only]

The number of items in the dataProvider.

This property can be used as the source for data binding.


Implementation
    public function get itemCount():int
labelFieldproperty 
labelField:Object  [read-write]

The property within each item in the dataProvider that contains the field used to determine the label for the item.

This property can be used as the source for data binding.


Implementation
    public function get labelField():Object
    public function set labelField(value:Object):void
layoutsproperty 
layouts:Array  [read-write]

The layouts that should be displayed within this layout.

This property can be used as the source for data binding.


Implementation
    public function get layouts():Array
    public function set layouts(value:Array):void
msPerRenderFrameproperty 
public var msPerRenderFrame:Number = 50

Determines how long (milliseconds) a layout will spend on a given frame to render X number of datums

nameproperty 
public var name:String

A string used to identify this layout.

palettesproperty 
public var palettes:Array

A placeholder for palettes used within this layout. Modifying this array will not have any effect on the rendering of the layout.

This property can be used as the source for data binding.

parentLayoutproperty 
parentLayout:AbstractLayout  [read-write]

A reference to the layout that contains this layout.

This property can be used as the source for data binding.


Implementation
    public function get parentLayout():AbstractLayout
    public function set parentLayout(value:AbstractLayout):void
referenceRepeaterproperty 
referenceRepeater:GeometryRepeater  [read-write]

A GeometryRepeater that will be applied to the drawingGeometries once for each item in the dataProvider.

This property can be used as the source for data binding.


Implementation
    public function get referenceRepeater():GeometryRepeater
    public function set referenceRepeater(value:GeometryRepeater):void
renderingproperty 
rendering:Boolean  [read-only]

Whether or not this layout is currently in a render cycle. Rendering can take place over several frames. By watching this property you can take an appropriate action handle artifacts for multiframe rendering, such as hiding the layout entirely.

This property can be used as the source for data binding.


Implementation
    public function get rendering():Boolean
showDataTipsproperty 
showDataTips:Boolean  [read-write]

A flag that indicates to DataCanvas that it should listen for mouse events that signal the need to create a data tip.


Implementation
    public function get showDataTips():Boolean
    public function set showDataTips(value:Boolean):void
spriteproperty 
sprite:AxiisSprite  [read-write]

The sprite this layout is currently rendering to.


Implementation
    protected function get sprite():AxiisSprite
    protected function set sprite(value:AxiisSprite):void
statesproperty 
states:Array  [read-write]

An array of states that should be applied to this layout.

As Layouts create children, each child sets up listeners on itself for the Layout's states' enterStateEvent and exitStateEvent events. When those events are triggered, the relevant state's apply and remove methods are called, respectively. This is usually used to modify the drawingGeometry of the Layout.


Implementation
    public function get states():Array
    public function set states(value:Array):void

See also

State
strokesproperty 
public var strokes:Array

A placeholder for strokes used within this layout. Modifying this array will not have any effect on the rendering of the layout.

This property can be used as the source for data binding.

visibleproperty 
visible:Boolean  [read-write]

Whether or not this layout is visible. Layouts that are not visible will return from their render methods immediately after they are called without making any changes to the display list.

This property can be used as the source for data binding.


Implementation
    public function get visible():Boolean
    public function set visible(value:Boolean):void
widthproperty 
width:Number  [read-write]

The width of the layout.

This property can be used as the source for data binding.


Implementation
    public function get width():Number
    public function set width(value:Number):void
xproperty 
x:Number  [read-write]

The horizontal position of the top left corner of this layout within its parent.

This property can be used as the source for data binding.


Implementation
    public function get x():Number
    public function set x(value:Number):void
yproperty 
y:Number  [read-write]

The vertical position of the top left corner of this layout within its parent.

This property can be used as the source for data binding.


Implementation
    public function get y():Number
    public function set y(value:Number):void
Constructor Detail
AbstractLayout()Constructor
public function AbstractLayout()

Constructor.

Method Detail
deselectChildren()method
protected function deselectChildren():void

Marks all children as deselected.

getProperty()method 
public function getProperty(obj:Object, propertyName:Object):*

Uses ObjectUtils.getProperty(this,obj,propertyName) to get a property on an object.

Parameters

obj:Object
 
propertyName:Object

Returns
*

See also

ObjectUtils.getProperty
getSprite()method 
public function getSprite(owner:DataCanvas):Sprite

Returns the Sprite associated with this layout if owner is in fact the owner of this layout.

Parameters

owner:DataCanvas

Returns
Sprite
invalidate()method 
public function invalidate():void

Notifies the DataCanvas that this layout needs to be rendered.

invalidateDataProvider()method 
public function invalidateDataProvider():void

Iterates over the items in the dataProvider and stores them in dataItems.

If the dataProvider is Array or ArrayCollection dataItems will contain each item. If dataProvider is an Object, dataItems will contain an the object's properties as they are exposed in a for..each loop.

registerOwner()method 
public function registerOwner(dataCanvas:DataCanvas):void

Registers a DisplayObject as the owner of this layout. Throws an error if the layout already has an owner.

Parameters

dataCanvas:DataCanvas

render()method 
public function render(newSprite:AxiisSprite = null):void

Draws this layout to the specified AxiisSprite.

If no sprite is provided this layout will use the last AxiisSprite it rendered to, if such an AxiisSprite exists. Otherwise this returns immediately.

This method is meant to be overridden by a subclass.

Parameters

newSprite:AxiisSprite (default = null) — The AxiisSprite this layout should render to.

Event Detail
itemDataTip Event
Event Object Type: flash.events.Event

Dispatched when an AxiisSprite is mousedOver.