Symbian
Symbian Developer Library

SYMBIAN OS V9.4

Feedback

[Index] [Previous] [Next]

#include <BASSND.H>
Link against: bafl.lib

Class TBaSystemSoundInfo

class TBaSystemSoundInfo;

Description

Provides functions that contain the information for a system sound. A sound may be a file, a tone or a fixed sequence.

The characteristics of a physical sound that corresponds to a logical sound are encapsulated in a TBaSystemSoundInfo object. You can get and set the physical sound for a logical sound through the functions provided by the BaSystemSound class.

Members

Defined in TBaSystemSoundInfo:


Construction and destruction


TBaSystemSoundInfo()

IMPORT_C TBaSystemSoundInfo();

Description

Constructs a default TBaSystemSoundInfo object. This object has a null type, default volume, default priority, null name, null fixed sequence, and tone of TBaSystemSoundInfo::TTone.


TBaSystemSoundInfo(const TBaSystemSoundType &,const TBaSystemSoundName &,TInt,TInt)

IMPORT_C TBaSystemSoundInfo(const TBaSystemSoundType &aType, const TBaSystemSoundName &aName, TInt aVolume=1,TInt aPriority=0);

Description

Constructs a TBaSystemSoundInfo object with the specified type and file name. The sound has default volume and priority.

Parameters

const TBaSystemSoundType &aType

Sound type

const TBuf &aName

Sound name

TInt aVolume

Sound volume

TInt aPriority

Sound priority


TBaSystemSoundInfo(const TBaSystemSoundType &,TInt,TInt,TInt)

IMPORT_C TBaSystemSoundInfo(const TBaSystemSoundType &aType, TInt aFixedSequence, TInt aVolume=1,TInt aPriority=0);

Description

Constructs a TBaSystemSoundInfo object with the specified type and sequence. The sound has default volume and priority.

Parameters

const TBaSystemSoundType &aType

Sound type

TInt aFixedSequence

Sound sequence

TInt aVolume

Sound volume

TInt aPriority

Sound priority


TBaSystemSoundInfo(const TBaSystemSoundType &,TTone,TInt,TInt)

IMPORT_C TBaSystemSoundInfo(const TBaSystemSoundType &aType, TTone aTone, TInt aVolume=1,TInt aPriority=0);

Description

Constructs a TBaSystemSoundInfo object with the specified type and tone. The sound has default volume and priority.

Parameters

const TBaSystemSoundType &aType

Sound type

TBaSystemSoundInfo::TTone aTone

Sound tone

TInt aVolume

Sound volume

TInt aPriority

Sound priority

[Top]


Member functions


SoundCategory()const

IMPORT_C TSoundCategory SoundCategory() const;

Description

Gets the sound's category.

Return value

TBaSystemSoundInfo::TSoundCategory

The system sound's category, or NULL if the sound is not a file, sequence, or tone.


FixedSequenceNumber()const

inline TInt FixedSequenceNumber() const;

Description

Gets the current sound's sequence.

Return value

TInt

The current sound's sequence.


FileName()const

inline TBaSystemSoundName FileName() const;

Description

Gets the current sound's file.

Return value

TBuf

The current sound's file.


Tone()const

inline TTone Tone() const;

Description

Gets the current system sound's tone.

Return value

TBaSystemSoundInfo::TTone

The current sound's tone.


SetFixedSequenceNumber(TInt)

IMPORT_C void SetFixedSequenceNumber(TInt aNumber);

Description

Replaces the current sound with the specified sequence number.

Parameters

TInt aNumber

The sequence number with which to replace the current sound.


SetFileName(const TBaSystemSoundName &)

IMPORT_C void SetFileName(const TBaSystemSoundName &aFileName);

Description

Replaces the current sound with the specified file.

Parameters

const TBuf &aFileName

The file with which to replace the current sound.


SetTone(const TTone &)

IMPORT_C void SetTone(const TTone &aTone);

Description

Replaces the current sound with the specified tone.

Parameters

const TBaSystemSoundInfo::TTone &aTone

The tone with which to replace the current sound.

[Top]


Member classes


Class TTone

class TTone;

Description

Provides functions to define a tone. Once defined, the tone can be encapsulated using the TBaSystemSoundInfo class and subsequently played.

Members

Defined in TBaSystemSoundInfo::TTone:

Construction and destruction


TTone()

inline TTone();

Description

Default constructor. Sets up a TBaSystemSoundInfo::TTone object with null frequency and duration.


TTone(TInt,TTimeIntervalMicroSeconds32)

inline TTone(TInt aFrequency, TTimeIntervalMicroSeconds32 aDuration);

Description

Constructor which sets up a TBaSystemSoundInfo::TTone object with specified frequency and duration.

Parameters

TInt aFrequency

The tone's frequency.

TTimeIntervalMicroSeconds32 aDuration

The tone's duration.

Member data


iFrequency

TInt iFrequency;

Description

Frequency of the tone.


iDuration

TTimeIntervalMicroSeconds32 iDuration;

Description

Duration of the tone.

[Top]


Member enumerations


Enum TSoundCategory

TSoundCategory

Description

Specifies the category of the system sound.

ENull

Specifies no system sound.

EFile

Specifies a file as the system sound.

ESequence

Specifies a sequence as the system sound.

ETone

Specifies a tone as the system sound.

[Top]


Member data


iType

TBaSystemSoundType iType;

Description


iVolume

TInt iVolume;

Description


iPriority

TInt iPriority;

Description