Subtitle

open class Subtitle: NSObject

Represents a subtitle relating to a specific file.

  • key

    The unique key for the subtitle

    Declaration

    Swift

    open dynamic var key = ""
  • The detected language of the subtitle

    Declaration

    Swift

    open dynamic var language: String?
  • The name of the file e.g MySubtitle.srt

    Declaration

    Swift

    open dynamic var name = ""
  • The ID of the file this subtitle is associated with

    Declaration

    Swift

    open dynamic var fileId = 0
  • Where the subtitle was obtained from

    Declaration

    Swift

    open var source: SubtitleSource = .folder
  • Generate the URL for the requested format

    Parameter

    Parameter format: The format to request. Defaults to .srt

    Returns

    The generated URL

    Declaration

    Swift

    open func url(forFormat format: SubtitleFormat = .srt) -> URL?

    Parameters

    format

    The format to request. Defaults to .srt

    Return Value

    The generated URL