sswf::TagStartSound Class Reference

Class used to start/stop a sound. More...

#include <libsswf.h>

Inheritance diagram for sswf::TagStartSound:

sswf::TagBase sswf::MemoryManager List of all members.

Public Member Functions

virtual ErrorManager::error_code_t Save (Data &data)
 Save the start sound tag in the Data buffer.
void SetInfo (SoundInfo *sound_info)
 Defines the sound info of this start sound tag.
 TagStartSound (TagBase *parent)
 Initialize a start sound tag.
virtual swf_type_t TypeFlags (void) const
 Returns the type flags of this start sound tag.

Private Member Functions

virtual ErrorManager::error_code_t PreSave (void)
 Test the validity of the start sound tag.

Private Attributes

SoundInfof_sound_info

Detailed Description

This class is used to start and/or stop a sound in an SWF animation.

In order to work properly, you must call sswf::TagStartSound::SetInfo(SoundInfo *sound_info) at least once.

See also:
sswf::TagStartSound::SetInfo(SoundInfo *sound_info)

SWF Alexis' Reference—Start Sound

SWF Alexis' Reference—swf_tag


Constructor & Destructor Documentation

TagStartSound::TagStartSound ( TagBase parent  ) 

This function initializes a start sound tag. This means setting the pointer to the sound info to NULL.

Parameters:
[in] parent The parent of this TagStartSound
See also:
sswf::TagStartSound::SetInfo(SoundInfo *sound_info)


Member Function Documentation

ErrorManager::error_code_t TagStartSound::PreSave ( void   )  [private, virtual]

This function makes sure that you have set a valid sound info.

If the sound info pointer is null, this function returns an error.

Returns:
sswf::ErrorManager::ERROR_CODE_START_SOUND_NO_INFO if no sound info was defined; no error otherwise

Reimplemented from sswf::TagBase.

ErrorManager::error_code_t TagStartSound::Save ( Data data  )  [virtual]

This function saves the start sound tag in the specified Data buffer. This calls the sswf::SoundInfo::Save(Data& data) function.

Parameters:
[in] data The Data buffer where the start sound tag is saved
Returns:
an error manager code
See also:
sswf::SoundInfo::Save(Data& data)

Implements sswf::TagBase.

void TagStartSound::SetInfo ( SoundInfo sound_info  ) 

This function saves the specified sound info pointer in the TagStartSound object.

Warning:
The sound_info structure will be used by the TagStartSound until replaced by a new pointer or set to NULL.
You are responsible to ensure that this structure remains valid until the object does not require it anymore.

TagBase::swf_type_t TagStartSound::TypeFlags ( void   )  const [virtual]

The start sound tag is a CONTROL tag.

The start sound tag has a reference to a sound (actually defined in the sound info.)

Returns:
A set of SWF TYPE flags
See also:
sswf::TagStartSound::SetInfo(SoundInfo *sound_info)

Implements sswf::TagBase.


Member Data Documentation

SoundInfo* sswf::TagStartSound::f_sound_info [private]


The documentation for this class was generated from the following files:
Generated on Tue Jun 26 02:36:46 2007 for libsswf by  doxygen 1.4.7