Packagecom.SeiON
Classpublic final class SeionClip
InheritanceSeionClip Inheritance SeionInstance Inheritance Object

The simplest way to play a sound.

SeionClip is a simple wrapper over both the native Sound and the _sndChannel object in Flash. Use SeionClip.create() to instantiate this class.

See also

create()


Public Properties
 PropertyDefined By
 Inheritedautodispose : Boolean
[read-only] Whether this sound is auto-disposable.
SeionInstance
  isPaused : Boolean
[override] [read-only] Is the playback paused? (ISeionControl)
SeionClip
  isPlaying : Boolean
[override] [read-only] Is the sound active? (ISeionInstance)
SeionClip
  length : Number
[override] [read-only] The total length of the clip, excluding repeats.
SeionClip
 Inheritedmanager : SeionGroup
[read-only] Returns the manager that holds this ISeionInstance.
SeionInstance
 Inheritedname : String
The name of the clip, non-unique.
SeionInstance
  offset : uint
[read-only] The delayed starting position.
SeionClip
 Inheritedpan : Number
Get: The panning as affected by its parent.
SeionInstance
  position : Number
[override] [read-only] How far into the clip we are.
SeionClip
  progress : Number
[override] [read-only] How far into the clip we are, from 0.0 - 1.0.
SeionClip
 Inheritedrepeat : int
How many times the SeionInstance is programmed to repeat itself.
SeionInstance
 InheritedrepeatLeft : int
[read-only] How many more times the SeionInstance has to repeat itself.
SeionInstance
 Inheritedsoundtransform : SoundTransform
[read-only] Returns the predefined sound properties of the sound.
SeionInstance
  truncate : uint
[read-only] The truncation from the ending position.
SeionClip
 Inheritedvolume : Number
Get: The volume as affected by its parent.
SeionInstance
Public Methods
 MethodDefined By
  
SeionClip(secretKey:*)
Please do not call this constructor directly; it will throw an error.
SeionClip
 Inherited
addEventListener(type:String, listener:Function, useCapture:Boolean = false, priority:int = 0, useWeakReference:Boolean = false):void
SeionInstance
  
create(name:String, manager:SeionGroup, snd:Sound, repeat:int, autodispose:Boolean = true, sndTransform:SoundTransform = null):SeionClip
[static] Creates a sound clip.
SeionClip
  
createExcerpt(name:String, manager:SeionGroup, snd:Sound, repeat:int, autodispose:Boolean, sndTransform:SoundTransform, offset:uint, truncate:uint):SeionClip
[static] Creates a sound clip that can be shortened.
SeionClip
 Inherited
dispatchEvent(event:Event):Boolean
SeionInstance
  
dispose():void
[override] Clears all references held.
SeionClip
 Inherited
hasEventListener(type:String):Boolean
SeionInstance
 Inherited
isDisposed(output:Boolean = true):Boolean
Is the SeionInstance already disposed of? (ISeionInstance)
SeionInstance
  
pause():void
[override] Pauses playback of sound.
SeionClip
  
play():void
[override] Plays the sound from the beginning again.
SeionClip
 Inherited
removeEventListener(type:String, listener:Function, useCapture:Boolean = false):void
SeionInstance
  
resume():void
[override] Resumes playback of sound.
SeionClip
  
stop():void
[override] Stops the sound and resets it to Zero.
SeionClip
 Inherited
willTrigger(type:String):Boolean
SeionInstance
Events
 Event Summary Defined By
 InheritedDefines the value when a SeionInstance finishes playback and does not repeat.SeionInstance
 InheritedDefines the value when a SeionInstance loops itself.SeionInstance
Property Detail
isPausedproperty
isPaused:Boolean  [read-only] [override]

Is the playback paused? (ISeionControl)


Implementation
    public function get isPaused():Boolean
isPlayingproperty 
isPlaying:Boolean  [read-only] [override]

Is the sound active? (ISeionInstance)


Implementation
    public function get isPlaying():Boolean
lengthproperty 
length:Number  [read-only] [override]

The total length of the clip, excluding repeats. In Milliseconds. (ISeionInstance)


Implementation
    public function get length():Number
offsetproperty 
offset:uint  [read-only]

The delayed starting position. In Milliseconds.


Implementation
    public function get offset():uint
positionproperty 
position:Number  [read-only] [override]

How far into the clip we are. In Milliseconds. (ISeionInstance)

Includes offsets or truncated durations, eg. a 10 second _snd with 5 seconds offset at starting position would report a position of 0, not 5.


Implementation
    public function get position():Number
progressproperty 
progress:Number  [read-only] [override]

How far into the clip we are, from 0.0 - 1.0. (ISeionInstance)

Includes offsets or truncations, eg. a 100 second _snd with 5 seconds offset at starting position would report a position of 0.0, not 0.95.


Implementation
    public function get progress():Number
truncateproperty 
truncate:uint  [read-only]

The truncation from the ending position. In Milliseconds.


Implementation
    public function get truncate():uint
Constructor Detail
SeionClip()Constructor
public function SeionClip(secretKey:*)

Please do not call this constructor directly; it will throw an error. Call it through SeionClip.create().

Parameters
secretKey:*

See also

Method Detail
create()method
public static function create(name:String, manager:SeionGroup, snd:Sound, repeat:int, autodispose:Boolean = true, sndTransform:SoundTransform = null):SeionClip

Creates a sound clip.

Parameters

name:String — Any name, even a non-unique one.
 
manager:SeionGroup — The SeionGroup that manages this SeionClip. Immutable.
 
snd:Sound — The sound data. Immutable.
 
repeat:int — How many times to repeat the clip.
 
autodispose:Boolean (default = true) — Whether the clip will auto-mark for GC. Immutable.
 
sndTransform:SoundTransform (default = null) — The fixed internal property for the sound.

Returns
SeionClip — A SeionClip is allocation was successful. Null if allocation failed, or autodispose is true.

See also

SeionInstance.name
SeionInstance.repeat
SeionInstance.soundtransform
SeionInstance.autodispose
createExcerpt()method 
public static function createExcerpt(name:String, manager:SeionGroup, snd:Sound, repeat:int, autodispose:Boolean, sndTransform:SoundTransform, offset:uint, truncate:uint):SeionClip

Creates a sound clip that can be shortened.

Parameters

name:String — Any name, even a non-unique one.
 
manager:SeionGroup — The SeionGroup that manages this SeionClip. Immutable.
 
snd:Sound — The sound data. Immutable.
 
repeat:int — How many times to repeat the clip.
 
autodispose:Boolean — Whether the clip will auto-mark for GC. Immutable.
 
sndTransform:SoundTransform — The fixed internal property for the sound.
 
offset:uint — The delayed starting position. In Milliseconds. Immutable.
 
truncate:uint — The truncation from the ending position. In Milliseconds. Immutable.

Returns
SeionClip — A SeionClip if allocation was successful. Null if allocation failed, or autodispose is true.

See also

SeionInstance.name
SeionInstance.repeat
SeionInstance.soundtransform
SeionInstance.autodispose
offset
truncate
dispose()method 
override public function dispose():void

Clears all references held. This object is now invalid. (ISeionInstance)

pause()method 
override public function pause():void

Pauses playback of sound. (ISeionControl)

play()method 
override public function play():void

Plays the sound from the beginning again. (ISeionInstance)

resume()method 
override public function resume():void

Resumes playback of sound. (ISeionControl)

stop()method 
override public function stop():void

Stops the sound and resets it to Zero. (ISeionInstance)