Files
BQP/srcs/RobotNet10/FleetManager/RobotNet10.FleetManager.Shared/DTOs/RobotModel/MapValidationResultDto.cs
2026-07-13 09:25:40 +07:00

81 lines
2.0 KiB
C#

namespace RobotNet10.FleetManager.Shared.DTOs.RobotModel;
/// <summary>
/// Map validation result for robot model
/// </summary>
public class MapValidationResultDto
{
/// <summary>
/// Whether the map data is valid after filtering and validation
/// </summary>
public bool IsValid { get; set; }
/// <summary>
/// List of validation errors
/// </summary>
public List<ValidationError> Errors { get; set; } = [];
/// <summary>
/// List of validation warnings
/// </summary>
public List<ValidationWarning> Warnings { get; set; } = [];
/// <summary>
/// Number of nodes removed during validation
/// </summary>
public int NodesRemoved { get; set; }
/// <summary>
/// Number of edges removed during validation
/// </summary>
public int EdgesRemoved { get; set; }
}
/// <summary>
/// Validation error information
/// </summary>
public class ValidationError
{
/// <summary>
/// Error code (e.g., "NODE_NO_EDGES", "EDGE_MISSING_START_NODE")
/// </summary>
public string Code { get; set; } = string.Empty;
/// <summary>
/// Human-readable error message
/// </summary>
public string Message { get; set; } = string.Empty;
/// <summary>
/// Entity ID that caused the error (NodeId or EdgeId)
/// </summary>
public string? EntityId { get; set; }
/// <summary>
/// Entity type ("Node" or "Edge")
/// </summary>
public string? EntityType { get; set; }
}
/// <summary>
/// Validation warning information
/// </summary>
public class ValidationWarning
{
/// <summary>
/// Warning code
/// </summary>
public string Code { get; set; } = string.Empty;
/// <summary>
/// Human-readable warning message
/// </summary>
public string Message { get; set; } = string.Empty;
/// <summary>
/// Entity ID related to the warning
/// </summary>
public string? EntityId { get; set; }
}