using System;

namespace Volpe.Cafe.Logging
{
    [Serializable]
    internal static class ThrowHelper
    {
        /// <summary>
        /// Throws: ArgumentOutOfRangeException(paramName, "Buffer count must be greater than or equal to one.")
        /// </summary>
        internal static void BufferCountTooSmall(string paramName)
        {
            throw new ArgumentOutOfRangeException(paramName, "Buffer count must be greater than or equal to one.");
        }

        /// <summary>
        /// Throws: ArgumentOutOfRangeException(paramName, "Log count must be greater than or equal to one.")
        /// </summary>
        internal static void LogCountTooSmall(string paramName)
        {
            throw new ArgumentOutOfRangeException(paramName, "Log count must be greater than or equal to one.");
        }

        /// <summary>
        /// Throws: ObjectDisposedException("The logger object is disposed.")
        /// </summary>
        internal static void LoggerDisposed()
        {
            throw new ObjectDisposedException(null, "The logger object is disposed.");
        }

        /// <summary>
        /// Throws: ArgumentOutOfRangeException(paramName, "Log level must be one of: Minimal, Default, or Debug.")
        /// </summary>
        internal static void InvalidLogLevel(string paramName)
        {
            throw new ArgumentOutOfRangeException(paramName, "Log level must be one of: Minimal, Default, or Debug.");
        }

    }
}
