Contents

numberOfLoops

The number of times the audio repeats playback.

Declaration

var numberOfLoops: Int { get set }

Discussion

The default value of 0 results in the sound playing once. Set a positive integer value to specify the number of times to repeat the sound. For example, a value of 1 plays the sound twice: the original sound and one repetition. Set a negative integer value to loop the sound continuously until you call the stop() method.

See Also

Configuring playback settings