37 lines
959 B
C#
37 lines
959 B
C#
|
|
using System.Text.Json.Serialization;
|
||
|
|
|
||
|
|
namespace YD_TrainingCompetition_Api.Models;
|
||
|
|
|
||
|
|
/// <summary>
|
||
|
|
/// 海康摄像头实时状态
|
||
|
|
/// </summary>
|
||
|
|
public sealed class HikvisionCameraStatus
|
||
|
|
{
|
||
|
|
[JsonPropertyName("deviceId")]
|
||
|
|
public string DeviceId { get; set; } = string.Empty;
|
||
|
|
|
||
|
|
[JsonPropertyName("ip")]
|
||
|
|
public string Ip { get; set; } = string.Empty;
|
||
|
|
|
||
|
|
[JsonPropertyName("online")]
|
||
|
|
public bool Online { get; set; }
|
||
|
|
|
||
|
|
[JsonPropertyName("armed")]
|
||
|
|
public bool Armed { get; set; }
|
||
|
|
|
||
|
|
[JsonPropertyName("userId")]
|
||
|
|
public int UserId { get; set; } = -1;
|
||
|
|
|
||
|
|
[JsonPropertyName("alarmHandle")]
|
||
|
|
public int AlarmHandle { get; set; } = -1;
|
||
|
|
|
||
|
|
[JsonPropertyName("lastAlarmTime")]
|
||
|
|
public DateTimeOffset? LastAlarmTime { get; set; }
|
||
|
|
|
||
|
|
[JsonPropertyName("lastSeen")]
|
||
|
|
public DateTimeOffset LastSeen { get; set; } = DateTimeOffset.UtcNow;
|
||
|
|
|
||
|
|
[JsonPropertyName("errorMessage")]
|
||
|
|
public string? ErrorMessage { get; set; }
|
||
|
|
}
|