using System;
using System.Collections.Generic;
using System.Text;

namespace Apewer.Web
{

    /// <summary>调度程序捕获的异常信息。</summary>
    public sealed class ApiCatch
    {

        ApiController _controller = null;
        ApiOptions _options = null;
        Exception _exception = null;

        /// <summary>调度程序调用的控制器。</summary>
        public ApiController Controller { get => _controller; }

        /// <summary>调度程序使用的 API 选项。</summary>
        public ApiOptions Options { get => _options; }

        /// <summary>已捕获的异常。</summary>
        public Exception Exception { get => _exception; }

        internal ApiCatch(ApiController controller, ApiOptions options, Exception exception)
        {
            _controller = controller;
            _options = options;
            _exception = exception;
        }

    }

}