﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace MyCLI.Core
{
    public interface ICLIManager
    {
        bool IsHelp { get; }

        /// <summary>
        /// Check if an argument exists in the loaded argument collection
        /// </summary>
        /// <param name="name">Name of the argument</param>
        /// <returns></returns>
        bool ArgumentExists(string name);

        /// <summary>
        /// Display Help content
        /// <param name="command">Main command</param>
        /// </summary>
        void DisplayHelp(string command);

        /// <summary>
        /// Get the value of an argument in the loaded argument collection
        /// </summary>
        /// <param name="name">Name of the argument</param>
        /// <returns></returns>
        string GetArgumentValue(string name);
        
        /// <summary>
        /// Load and validate the given arguments
        /// </summary>
        /// <param name="args">Command arguments</param>
        void LoadArguments(string[] args);

        /// <summary>
        /// Setup available arguments
        /// </summary>
        /// <param name="arg">Avaiable argument</param>
        void SetupArg(Func<CLIArgument> arg);
    }
}
