AudioPlayerDisplayDelegate
public protocol AudioPlayerDisplayDelegate : AnyObject
The DisplayPlayerAgent delegate is used to notify observers when a player template directive is received.
-
Tells the delegate that the specified template should be displayed.
Declaration
Swift
func audioPlayerDisplayShouldRender(template: AudioPlayerDisplayTemplate, completion: @escaping (AnyObject?) -> Void)Parameters
templateThe player template to display.
-
Tells the delegate that the specified template should be removed from the screen.
Declaration
Swift
func audioPlayerDisplayDidClear(template: AudioPlayerDisplayTemplate)Parameters
templateThe template to remove from the screen.
-
Tells the delegate that the specified template should be updated from the screen.
Declaration
Swift
func audioPlayerDisplayShouldUpdateMetadata(payload: Data, header: Downstream.Header)Parameters
templateThe template to update the screen.
headerThe header of the originally handled directive.
-
Tells the delegate that the displayed template should show lyrics
Declaration
Swift
func audioPlayerDisplayShouldShowLyrics(header: Downstream.Header, completion: @escaping (Bool) -> Void)Parameters
headerThe header of the originally handled directive.
completionWhether succeeded or not
-
Tells the delegate that the displayed template should hide lyrics
Declaration
Swift
func audioPlayerDisplayShouldHideLyrics(header: Downstream.Header, completion: @escaping (Bool) -> Void)Parameters
headerThe header of the originally handled directive.
completionWhether succeeded or not
-
Tells the delegate that the displayed template should scroll with given direction.
Declaration
Swift
func audioPlayerDisplayShouldControlLyricsPage(direction: AudioPlayerDisplayControlPayload.Direction, header: Downstream.Header, completion: @escaping (Bool) -> Void)Parameters
directionDirection to scroll.
headerThe header of the originally handled directive.
completionWhether succeeded or not
-
<#Description#>
Declaration
Swift
func audioPlayerIsLyricsVisible(completion: @escaping (Bool) -> Void)Parameters
completion<#completion description#>
View on GitHub
AudioPlayerDisplayDelegate Protocol Reference