Packagesystem.process
Classpublic dynamic class Pause
InheritancePause Inheritance CoreAction Inheritance Task Inheritance Object
Implements Serializable, Startable, Stoppable

The pause command is used to pause the currently running process until a specific delay is not finished or until the user stop it.

Example :

                  
     import system.events.Action ;
     import system.process.Pause ;
     
     var finish:Function = function( action:Action ):void
     {
         trace( "finish" ) ;
     }
     
     var start:Function = function( action:Action ):void
     {
         trace( "start" ) ;
     }
     
     var pause:Pause = new Pause( 10 ) ; // 10 seconds
     
     pause.startIt.connect( start ) ;
     pause.finishIt.connect( finish ) ;
     
     pause.run() ;
     
               



Public Properties
 PropertyDefined By
 InheritedchangeIt : Signaler
This signal emit when the notifyChanged method is invoked.
CoreAction
 InheritedclearIt : Signaler
This signal emit when the notifyCleared method is invoked.
CoreAction
  delay : Number
[read-only] Indicates the delay of the pause in ms.
Pause
  duration : Number
Indicates the duration of the process.
Pause
 InheritedfinishIt : Signaler
This signal emit when the notifyFinished method is invoked.
Task
 InheritedinfoIt : Signaler
This signal emit when the notifyInfo method is invoked.
CoreAction
 Inheritedlogger : Logger
Determinates the internal Logger reference of this Loggable object.
Task
 Inheritedlooping : Boolean
The flag to determinate if the Action object is looped.
CoreAction
 InheritedloopIt : Signaler
This signal emit when the notifyLooped method is invoked.
CoreAction
 InheritedpauseIt : Signaler
This signal emit when the notifyPause method is invoked.
CoreAction
 Inheritedphase : String
[read-only] The current phase of the action.
Task
 InheritedprogressIt : Signaler
This signal emit when the notifyProgress method is invoked.
CoreAction
 InheritedresumeIt : Signaler
This signal emit when the notifyResumed method is invoked.
CoreAction
 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
 InheritedstopIt : Signaler
This signal emit when the notifyStopped method is invoked.
CoreAction
 InheritedtimeoutIt : Signaler
This signal emit when the notifyTimeOut method is invoked.
CoreAction
  useSeconds : Boolean
Indicates if the pause use seconds or not.
Pause
Public Methods
 MethodDefined By
  
Pause(duration:Number = 0, useSeconds:Boolean = true)
Creates a new Pause instance.
Pause
  
clone():*
[override] Returns a shallow copy of this object.
Pause
 Inherited
isLocked():Boolean
Returns true if the object is locked.
Task
 Inherited
lock():void
Locks the object.
Task
 Inherited
Notify when the process is changed.
CoreAction
 Inherited
Notify when the process is cleared.
CoreAction
 Inherited
Notify an ActionEvent when the process is finished.
Task
 Inherited
notifyInfo(info:*):void
Notify a specific information when the process is changed.
CoreAction
 Inherited
Notify when the process is looped.
CoreAction
 Inherited
Notify when the process is paused.
CoreAction
 Inherited
Notify when the process is in progress.
CoreAction
 Inherited
Notify when the process is resumed.
CoreAction
 Inherited
Notify an ActionEvent when the process is started.
Task
 Inherited
Notify when the process is stopped.
CoreAction
 Inherited
Notify when the process is out of time.
CoreAction
  
run(... arguments):void
[override] Runs the process.
Pause
  
start():void
Start the pause process.
Pause
  
stop():void
Stop the pause process.
Pause
  
toSource(indent:int = 0):String
Returns the String source representation of the object.
Pause
  
toString():String
Returns the string representation of this instance.
Pause
 Inherited
unlock():void
Unlocks the display.
Task
Protected Methods
 MethodDefined By
 Inherited
setRunning(b:Boolean):void
Changes the running property value.
Task
Property Detail
delayproperty
delay:Number  [read-only]

Indicates the delay of the pause in ms. This property use the duration and useSeconds properties to defined the delay.


Implementation
    public function get delay():Number

See also

durationproperty 
duration:Number

Indicates the duration of the process.


Implementation
    public function get duration():Number
    public function set duration(value:Number):void
useSecondsproperty 
useSeconds:Boolean

Indicates if the pause use seconds or not.


Implementation
    public function get useSeconds():Boolean
    public function set useSeconds(value:Boolean):void
Constructor Detail
Pause()Constructor
public function Pause(duration:Number = 0, useSeconds:Boolean = true)

Creates a new Pause instance.

Parameters
duration:Number (default = 0) — the duration of the pause.
 
useSeconds:Boolean (default = true) — the flag to indicates if the duration is in second or not.
Method Detail
clone()method
override public function clone():*

Returns a shallow copy of this object.

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

Runs the process.

Parameters

... arguments

start()method 
public function start():void

Start the pause process.

stop()method 
public function stop():void

Stop the pause process.

toSource()method 
public function toSource(indent:int = 0):String

Returns the String source representation of the object.

Parameters

indent:int (default = 0)

Returns
String — a string representation the source code of the object.
toString()method 
public function toString():String

Returns the string representation of this instance.

Returns
String — the string representation of this instance.