using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using Torch.API.Managers;
namespace Torch.API.Session
{
///
/// Creates a manager for the given session if applicable.
///
///
/// This is for creating managers that will live inside the session, not the manager that controls sesssions.
///
/// The session to construct a bound manager for
/// The manager that will live in the session, or null if none.
public delegate IManager SessionManagerFactory(ITorchSession session);
///
/// Manages the creation and destruction of instances for each created by Space Engineers.
///
public interface ITorchSessionManager : IManager
{
///
/// The currently running session
///
ITorchSession CurrentSession { get; }
///
/// Adds the given factory as a supplier for session based managers
///
/// Session based manager supplier
/// true if added, false if already present
/// If the factory is null
bool AddFactory(SessionManagerFactory factory);
///
/// Remove the given factory from the suppliers for session based managers
///
/// Session based manager supplier
/// true if removed, false if not present
/// If the factory is null
bool RemoveFactory(SessionManagerFactory factory);
}
}