34 lines
836 B
C#
34 lines
836 B
C#
|
|
using System.Text.Json.Serialization;
|
||
|
|
|
||
|
|
namespace YD_TrainingCompetition_Api.Models;
|
||
|
|
|
||
|
|
/// <summary>
|
||
|
|
/// 摄像头连接配置
|
||
|
|
/// </summary>
|
||
|
|
public sealed class CameraConfig
|
||
|
|
{
|
||
|
|
[JsonPropertyName("deviceId")]
|
||
|
|
public string DeviceId { get; set; } = string.Empty;
|
||
|
|
|
||
|
|
[JsonPropertyName("ip")]
|
||
|
|
public string Ip { get; set; } = string.Empty;
|
||
|
|
|
||
|
|
[JsonPropertyName("port")]
|
||
|
|
public ushort Port { get; set; } = 8000;
|
||
|
|
|
||
|
|
[JsonPropertyName("userName")]
|
||
|
|
public string UserName { get; set; } = "admin";
|
||
|
|
|
||
|
|
[JsonPropertyName("password")]
|
||
|
|
public string Password { get; set; } = string.Empty;
|
||
|
|
|
||
|
|
[JsonPropertyName("channel")]
|
||
|
|
public int Channel { get; set; } = 1;
|
||
|
|
|
||
|
|
/// <summary>
|
||
|
|
/// 是否启用该摄像头
|
||
|
|
/// </summary>
|
||
|
|
[JsonPropertyName("enabled")]
|
||
|
|
public bool Enabled { get; set; } = true;
|
||
|
|
}
|