mirror of
				https://github.com/jellyfin/jellyfin.git
				synced 2025-11-04 03:27:21 -05:00 
			
		
		
		
	
		
			
				
	
	
		
			36 lines
		
	
	
		
			1.4 KiB
		
	
	
	
		
			C#
		
	
	
	
	
	
			
		
		
	
	
			36 lines
		
	
	
		
			1.4 KiB
		
	
	
	
		
			C#
		
	
	
	
	
	
using MediaBrowser.Controller.Entities;
 | 
						|
using MediaBrowser.Model.Dto;
 | 
						|
using System.Collections.Generic;
 | 
						|
using System.Threading;
 | 
						|
using System.Threading.Tasks;
 | 
						|
 | 
						|
namespace MediaBrowser.Controller.Library
 | 
						|
{
 | 
						|
    public interface IMediaSourceProvider
 | 
						|
    {
 | 
						|
        /// <summary>
 | 
						|
        /// Gets the media sources.
 | 
						|
        /// </summary>
 | 
						|
        /// <param name="item">The item.</param>
 | 
						|
        /// <param name="cancellationToken">The cancellation token.</param>
 | 
						|
        /// <returns>Task<IEnumerable<MediaSourceInfo>>.</returns>
 | 
						|
        Task<IEnumerable<MediaSourceInfo>> GetMediaSources(IHasMediaSources item, CancellationToken cancellationToken);
 | 
						|
 | 
						|
        /// <summary>
 | 
						|
        /// Opens the media source.
 | 
						|
        /// </summary>
 | 
						|
        /// <param name="openToken">The open token.</param>
 | 
						|
        /// <param name="cancellationToken">The cancellation token.</param>
 | 
						|
        /// <returns>Task<MediaSourceInfo>.</returns>
 | 
						|
        Task<MediaSourceInfo> OpenMediaSource(string openToken, CancellationToken cancellationToken);
 | 
						|
 | 
						|
        /// <summary>
 | 
						|
        /// Closes the media source.
 | 
						|
        /// </summary>
 | 
						|
        /// <param name="liveStreamId">The live stream identifier.</param>
 | 
						|
        /// <param name="cancellationToken">The cancellation token.</param>
 | 
						|
        /// <returns>Task.</returns>
 | 
						|
        Task CloseMediaSource(string liveStreamId, CancellationToken cancellationToken);
 | 
						|
    }
 | 
						|
}
 |