Amazon Vinyl
    Preparing search index...

    Interface DrmController

    DrmController manages media keys and sessions, provides tracks a way to declare their content protections.

    interface DrmController {
        error: Error | null;
        closeSessions(): void;
        configure(options: Maybe<Partial<DrmOptions>>): void;
        hasAnyListeners(): boolean;
        hasListeners(type: keyof DrmControllerEventMap): boolean;
        initializeForPlayback(
            drmInfo: MediaFormatMetadata | null,
            options?: DrmPlaybackOptions,
        ): void;
        isEmeSupported(): boolean;
        isSupported(drmInfo: MediaFormatMetadata): Promise<DrmKeySystemSupport>;
        on<K extends keyof DrmControllerEventMap>(
            type: K,
            handler: EventHandler<DrmControllerEventMap[K]>,
            options?: SignalOptions,
        ): Unsubscribe;
        reset(): void;
        setBufferingDrmInfo(
            drmInfo: MediaFormatMetadata | null,
            options?: DrmPlaybackOptions,
        ): void;
    }

    Hierarchy (View Summary)

    Implemented by

    Index
    error: Error | null

    The last error emitted. Use reset to reset error state.

    • Clears all active DRM sessions. This should not be called unless the audio source has been cleared.

      Returns void

    • Initializes media keys if they have not yet been created and attached, creates a key session if the selected DrmProtection contains PSSH data.

      The first supported key system will be used. Once a key system has been set, it cannot be changed, all future content protections will be expected to contain the supported key system.

      Parameters

      Returns void