Packagegraphics.transitions
Classpublic class FrameTimer
InheritanceFrameTimer Inheritance FrameEngine Inheritance Task Inheritance Object
Implements ITimer

Constructs a new FrameTimer object with the specified delay and repeat state. This timer use the frames by second of the animation. The timer does not start automatically, you much call the start() method to start it.



Public Properties
 PropertyDefined By
  complete : Signaler
[read-only] The timer complete signal reference.
FrameTimer
  currentCount : int
[read-only] The total number of times the timer has fired since it started at zero.
FrameTimer
  delay : Number
The delay, in milliseconds, between timer events.
FrameTimer
 InheritedenterFrame : Signaler
[read-only] The enterFrame signal reference of the frame engine.
FrameEngine
 InheritedfinishIt : Signaler
This signal emit when the notifyFinished method is invoked.
Task
 Inheritedlogger : Logger
Determinates the internal Logger reference of this Loggable object.
Task
 Inheritedphase : String
[read-only] The current phase of the action.
Task
  repeatCount : int
The total number of times the timer is set to run.
FrameTimer
 Inheritedrunning : Boolean
[read-only] Indicates true if the process is in progress.
Task
 InheritedstartIt : Signaler
This signal emit when the notifyStarted method is invoked.
Task
  timer : Signaler
[read-only] The timer signal reference.
FrameTimer
Protected Properties
 PropertyDefined By
  _count : int
The internal counter of the timer.
FrameTimer
  _delay : Number
The internal delay of the timer.
FrameTimer
  _lastTime : uint
The internal
FrameTimer
  _next : Number = 0
The next value.
FrameTimer
  _repeatCount : int
The internal repeat counter of the timer.
FrameTimer
Public Methods
 MethodDefined By
  
FrameTimer(delay:Number = 0, repeatCount:int = 0)
Creates a new FrameTimer instance.
FrameTimer
  
clone():*
[override] Returns a shallow copy of this object.
FrameTimer
 Inherited
isLocked():Boolean
Returns true if the object is locked.
Task
 Inherited
lock():void
Locks the object.
Task
 Inherited
Notify an ActionEvent when the process is finished.
Task
 Inherited
Notify an ActionEvent when the process is started.
Task
  
reset():void
Stops the timer, if it is running, and sets the currentCount property back to 0, like the reset button of a stopwatch.
FrameTimer
 Inherited
run(... arguments):void
[override] Run the process.
FrameEngine
 Inherited
start():void
Start the process.
FrameEngine
 Inherited
stop():void
Stop the process.
FrameEngine
 Inherited
unlock():void
Unlocks the display.
Task
Protected Methods
 MethodDefined By
  
__enterFrame__(e:Event = null):void
[override] Invoked when the frame engine is in progress.
FrameTimer
 Inherited
setRunning(b:Boolean):void
Changes the running property value.
Task
Property Detail
_countproperty
protected var _count:int

The internal counter of the timer.

_delayproperty 
protected var _delay:Number

The internal delay of the timer.

_lastTimeproperty 
protected var _lastTime:uint

The internal

_nextproperty 
protected var _next:Number = 0

The next value.

_repeatCountproperty 
protected var _repeatCount:int

The internal repeat counter of the timer.

completeproperty 
complete:Signaler  [read-only]

The timer complete signal reference.


Implementation
    public function get complete():Signaler
currentCountproperty 
currentCount:int  [read-only]

The total number of times the timer has fired since it started at zero.


Implementation
    public function get currentCount():int
delayproperty 
delay:Number

The delay, in milliseconds, between timer events.


Implementation
    public function get delay():Number
    public function set delay(value:Number):void

Throws
Error — Throws an exception if the delay specified is negative or not a finite number.
repeatCountproperty 
repeatCount:int

The total number of times the timer is set to run. If the repeat count is set to 0, the timer continues forever or until the stop() method is invoked or the program stops.


Implementation
    public function get repeatCount():int
    public function set repeatCount(value:int):void
timerproperty 
timer:Signaler  [read-only]

The timer signal reference.


Implementation
    public function get timer():Signaler
Constructor Detail
FrameTimer()Constructor
public function FrameTimer(delay:Number = 0, repeatCount:int = 0)

Creates a new FrameTimer instance. The timer does not start automatically; you must call the start() method to start it.

Parameters
delay:Number (default = 0) — The delay between timer events, in milliseconds.
 
repeatCount:int (default = 0) — Specifies the number of repetitions. If zero, the timer repeats infinitely. If nonzero, the timer runs the specified number of times and then stops.
Method Detail
__enterFrame__()method
override protected function __enterFrame__(e:Event = null):void

Invoked when the frame engine is in progress.

Parameters

e:Event (default = null)

clone()method 
override public function clone():*

Returns a shallow copy of this object.

Returns
* — a shallow copy of this object.
reset()method 
public function reset():void

Stops the timer, if it is running, and sets the currentCount property back to 0, like the reset button of a stopwatch.