Packageasgard.display
Classpublic class CoreSprite
InheritanceCoreSprite Inheritance flash.display.Sprite
ImplementsIDisplayObject
SubclassesAbstractComponent, Background, PolyLineBackground

The CoreSprite class extends the flash.display.Sprite class and implements the IDisplayObject interface.

Example :

     import asgard.display.CoreSprite ;
     import asgard.display.DisplayObjectCollector ;
     
     var sprite:CoreSprite = new CoreSprite( "my_sprite" ) ;
     
     sprite.graphics.beginFill( 0xFF0000 , 100 ) ;
     sprite.graphics.drawRect( 0, 0, 200, 160 ) ;
     
     addChild( sprite ) ;
     
     trace( "DisplayObject contains 'my_sprite' : " + DisplayObjectCollector.contains( "my_sprite" ) ) ;
     trace( DisplayObjectCollector.get( "my_sprite" ) ) ;
     



Public Properties
 PropertyDefined by
  id : *
Returns the id of this object.
CoreSprite
  isConfigurable : Boolean
Indicates if the display is configurable.
CoreSprite
Public Methods
 MethodDefined by
  
CoreSprite(id:* = null, isConfigurable:Boolean = false, name:String = null)
Creates a new CoreSprite instance.
CoreSprite
  
Returns the internal ILogger reference of this ILogable object.
CoreSprite
  
hashCode():uint
Returns a hashcode value for the object.
CoreSprite
  
isLocked():Boolean
Returns true if the object is locked.
CoreSprite
  
lock():void
Locks the object.
CoreSprite
  
resetLock():void
Reset the lock security of the display.
CoreSprite
  
setLogger(log:ILogger = null):void
Sets the internal ILogger reference of this ILogable object.
CoreSprite
  
setup():void
Setup the IConfigurable object.
CoreSprite
  
toString():String
Returns the String representation of this object.
CoreSprite
  
unlock():void
Unlocks the display.
CoreSprite
  
update():void
Update the display.
CoreSprite
Protected Methods
 MethodDefined by
  
addedToStage(e:Event = null):void
Invoked when the display is added to the stage.
CoreSprite
  
removedFromStage(e:Event = null):void
Invoked when the display is removed from the stage.
CoreSprite
Property detail
idproperty
id:*  [read-write]

Returns the id of this object.

Implementation
    public function get id():*
    public function set id(value:*):void
isConfigurableproperty 
isConfigurable:Boolean  [read-write]

Indicates if the display is configurable.

Implementation
    public function get isConfigurable():Boolean
    public function set isConfigurable(value:Boolean):void
Constructor detail
CoreSprite()constructor
public function CoreSprite(id:* = null, isConfigurable:Boolean = false, name:String = null)

Creates a new CoreSprite instance.

Parameters
id:* (default = null) — Indicates the id of the object.
 
isConfigurable:Boolean (default = false) — This flag indicates if the IConfigurable object is register in the ConfigCollector.
 
name:String (default = null) — Indicates the instance name of the object.
Method detail
addedToStage()method
protected function addedToStage(e:Event = null):void

Invoked when the display is added to the stage.

Parameters
e:Event (default = null)
getLogger()method 
public function getLogger():ILogger

Returns the internal ILogger reference of this ILogable object.

Returns
ILogger — the internal ILogger reference of this ILogable object.
hashCode()method 
public function hashCode():uint

Returns a hashcode value for the object.

Returns
uint — a hashcode value for the object.
isLocked()method 
public function isLocked():Boolean

Returns true if the object is locked.

Returns
Booleantrue if the object is locked.
lock()method 
public function lock():void

Locks the object.

removedFromStage()method 
protected function removedFromStage(e:Event = null):void

Invoked when the display is removed from the stage.

Parameters
e:Event (default = null)
resetLock()method 
public function resetLock():void

Reset the lock security of the display.

setLogger()method 
public function setLogger(log:ILogger = null):void

Sets the internal ILogger reference of this ILogable object.

Parameters
log:ILogger (default = null)
setup()method 
public function setup():void

Setup the IConfigurable object.

toString()method 
public override function toString():String

Returns the String representation of this object.

Returns
String — the String representation of this object.
unlock()method 
public function unlock():void

Unlocks the display.

update()method 
public function update():void

Update the display. You must override this method. This method is launch by the setup() method when the Config is checked.