Files
simapi-net/Configurations/SimApiOptions.cs
T

38 lines
1.0 KiB
C#
Raw Normal View History

using System;
namespace SimApi.Configs
{
public class SimApiOptions
{
2022-06-29 02:50:15 +08:00
public bool EnableCors { get; set; } = false;
public bool EnableSimApiAuth { get; set; } = false;
2022-06-29 02:50:15 +08:00
public bool EnableSimApiDoc { get; set; } = false;
public bool EnableSimApiException { get; set; } = false;
public bool EnableSimApiStorage { get; set; } = false;
2022-06-29 02:50:15 +08:00
public bool EnableForwardHeaders { get; set; } = false;
public bool EnableLowerUrl { get; set; } = false;
public bool EnableLogger { get; set; } = false;
2021-06-05 14:33:59 +08:00
public SimApiDocOptions SimApiDocOptions { get; set; } = new SimApiDocOptions();
2022-06-29 02:50:15 +08:00
2021-06-05 14:33:59 +08:00
public SimApiStorageOptions SimApiStorageOptions { get; set; } = new SimApiStorageOptions();
public void ConfigureSimApiDoc(Action<SimApiDocOptions> options = null)
{
options?.Invoke(SimApiDocOptions);
}
public void ConfigureSimApiStorage(Action<SimApiStorageOptions> options = null)
{
options?.Invoke(SimApiStorageOptions);
}
}
}