Amazon Developer

as

Settings
Sign out
Notifications
Alexa
Amazon Appstore
Ring
AWS
Documentation
Support
Contact Us
My Cases
Get Started
Design and Develop
Publish
Reference
Support
Native
Skip to main content

Interface ISoundPlayer

interface ISoundPlayer
Extends com.amazon.apmf.IStandard Interface for encapsulating ISoundPlayer module

Methods

play()

void play()
Plays the stream of the associated sound

pause()

void pause()
Pause the stream of the associated sound

stop()

void stop()
Stops the stream of the associated sound

setRepeatCount()

void setRepeatCount(i32 repeatCount)
Sets number of iterations to repeat the associated sound during Play API call.

Parameters

repeatCount
i32 — Required number of iterations to play sound

setVolume()

void setVolume(i32 volume)
Sets volume of the stream for the associated sound

Parameters

volume
i32 — Required volume to be applied for the stream. Valid range is 0-100.

Throws


setPlaybackRate()

void setPlaybackRate(float playbackRate)
Sets playback rate for given sound

Parameters

playbackRate
float — Required to play sound at. This rate should correspond to a rate provided by getSupportedPlaybackRates.

Throws


Last modified on October 29, 2026