VersaPlayer

open class VersaPlayer : AVPlayer, AVAssetResourceLoaderDelegate

Undocumented

  • Notification key to extract info

    See more

    Declaration

    Swift

    public enum VPlayerNotificationInfoKey : String
  • Notification name to post

    See more

    Declaration

    Swift

    public enum VPlayerNotificationName : String
  • VersaPlayer instance

    Declaration

    Swift

    public var handler: VersaPlayerView!
  • Caption text style rules

    Declaration

    Swift

    lazy public var captionStyling: VersaPlayerCaptionStyling { get set }
  • Whether player is buffering

    Declaration

    Swift

    public var isBuffering: Bool
  • Play content

    Declaration

    Swift

    override open func play()
  • Pause content

    Declaration

    Swift

    override open func pause()
  • Replace current item with a new one

    Declaration

    Swift

    override open func replaceCurrentItem(with item: AVPlayerItem?)

    Parameters

    item

    AVPlayer item instance to be added

  • Start time

    Declaration

    Swift

    open func startTime() -> CMTime

    Return Value

    Player’s current item start time as CMTime

  • End time

    Declaration

    Swift

    open func endTime() -> CMTime

    Return Value

    Player’s current item end time as CMTime

  • Prepare players playback delegate observers

    Declaration

    Swift

    open func preparePlayerPlaybackDelegate()
  • Value observer

    Declaration

    Swift

    override open func observeValue(forKeyPath keyPath: String?, of object: Any?, change: [NSKeyValueChangeKey : Any]?, context: UnsafeMutableRawPointer?)
  • Undocumented

    Declaration

    Swift

    public func resourceLoader(_ resourceLoader: AVAssetResourceLoader, shouldWaitForLoadingOfRequestedResource loadingRequest: AVAssetResourceLoadingRequest) -> Bool