Packageardisia.components.clocks
Classpublic class ClockBase
InheritanceClockBase Inheritance spark.components.Group
Subclasses ClockAnalog, ClockDigital

Base class for the ClockAnalog and ClockDigital classes.

View the technical documentation on the Ardisia Labs website for more information.

Default MXML PropertymxmlContent



Public Properties
 PropertyDefined By
  isRunning : Boolean
[read-only] Returns true when the clock is running.
ClockBase
  updateInterval : Number
The interval in milliseconds between clock updates.
ClockBase
  use24HourMode : Boolean
Set to true to display a clock using a 24 hour format.
ClockBase
  useUTC : Boolean
Set to true to display UTC time, rather than local time.
ClockBase
  utcOffsetHours : Number
The hours to offset from UTC for display.
ClockBase
  utcOffsetMinutes : Number
The minutes to offset from UTC for display.
ClockBase
Public Methods
 MethodDefined By
  
ClockBase
  
dispose():void
Call to remove the component from the display list and remove any event listeners.
ClockBase
  
start():void
Start the clock.
ClockBase
  
stop():void
Stop the clock.
ClockBase
  
update():void
Update the clock.
ClockBase
Protected Methods
 MethodDefined By
  
timerHandler(event:TimerEvent):void
Handles events from the timer.
ClockBase
Events
 Event Summary Defined By
  Dispatched when the clock starts running.ClockBase
  Dispatched when the clock stops running.ClockBase
Property Detail
isRunningproperty
isRunning:Boolean  [read-only]

Returns true when the clock is running.

The default value is false.


Implementation
    public function get isRunning():Boolean
updateIntervalproperty 
updateInterval:Number

The interval in milliseconds between clock updates.

Minimum of 1000.

The default value is 1000 (1 second).


Implementation
    public function get updateInterval():Number
    public function set updateInterval(value:Number):void
use24HourModeproperty 
use24HourMode:Boolean

Set to true to display a clock using a 24 hour format.

The default value is false.


Implementation
    public function get use24HourMode():Boolean
    public function set use24HourMode(value:Boolean):void
useUTCproperty 
useUTC:Boolean

Set to true to display UTC time, rather than local time.

The default value is false.


Implementation
    public function get useUTC():Boolean
    public function set useUTC(value:Boolean):void
utcOffsetHoursproperty 
utcOffsetHours:Number

The hours to offset from UTC for display. Only relevant if the "useUTC" property is true.

The default value is 0.


Implementation
    public function get utcOffsetHours():Number
    public function set utcOffsetHours(value:Number):void
utcOffsetMinutesproperty 
utcOffsetMinutes:Number

The minutes to offset from UTC for display. Only relevant if the "useUTC" property is true.

The default value is 0.


Implementation
    public function get utcOffsetMinutes():Number
    public function set utcOffsetMinutes(value:Number):void
Constructor Detail
ClockBase()Constructor
public function ClockBase()



Method Detail
dispose()method
public function dispose():void

Call to remove the component from the display list and remove any event listeners.

start()method 
public function start():void

Start the clock.

stop()method 
public function stop():void

Stop the clock.

timerHandler()method 
protected function timerHandler(event:TimerEvent):void

Handles events from the timer.

Parameters

event:TimerEvent — the TimerEvent that triggered the handler

update()method 
public function update():void

Update the clock.

Event Detail
clockStart Event
Event Object Type: ardisia.components.clocks.events.ClockEvent
ClockEvent.type property = ardisia.components.clocks.events.ClockEvent

Dispatched when the clock starts running.

clockStop Event  
Event Object Type: ardisia.components.clocks.events.ClockEvent
ClockEvent.type property = ardisia.components.clocks.events.ClockEvent

Dispatched when the clock stops running.