using System.Collections.Generic;
using System.Threading.Tasks;
namespace Timeline.Services.Api
{
    /// 
    /// Service that controls highlight timeline.
    /// 
    public interface IHighlightTimelineService
    {
        /// 
        /// Get all highlight timelines in order.
        /// 
        /// Id list of all highlight timelines.
        Task> GetHighlightTimelinesAsync();
        /// 
        /// Check if a timeline is highlight timeline.
        /// 
        /// Timeline id.
        /// If true it will throw if timeline does not exist.
        /// True if timeline is highlight. Otherwise false.
        /// Thrown when timeline does not exist and  is true.
        Task IsHighlightTimelineAsync(long timelineId, bool checkTimelineExistence = true);
        /// 
        /// Add a timeline to highlight list.
        /// 
        /// The timeline id.
        /// The user id of operator.
        /// True if timeline is actually added to highligh. False if it already is.
        /// Thrown when timeline with given id does not exist.
        /// Thrown when user with given operator id does not exist.
        Task AddHighlightTimelineAsync(long timelineId, long? operatorId);
        /// 
        /// Remove a timeline from highlight list.
        /// 
        /// The timeline id.
        /// The user id of operator.
        /// True if deletion is actually performed. Otherwise false (timeline was not in the list).
        /// Thrown when timeline with given id does not exist.
        /// Thrown when user with given operator id does not exist.
        Task RemoveHighlightTimelineAsync(long timelineId, long? operatorId);
        /// 
        /// Move a highlight timeline to a new position.
        /// 
        /// The timeline name.
        /// The new position. Starts at 1.
        /// Thrown when timeline with given id does not exist.
        /// Thrown when given timeline is not a highlight timeline.
        /// 
        /// If  is smaller than 1. Then move the timeline to head.
        /// If  is bigger than total count. Then move the timeline to tail.
        /// 
        Task MoveHighlightTimelineAsync(long timelineId, long newPosition);
    }
}