2025-10-06 19:32:45 +08:00
|
|
|
using DMS.Core.Models;
|
2025-09-09 15:28:07 +08:00
|
|
|
|
2025-09-16 12:29:09 +08:00
|
|
|
namespace DMS.Application.Interfaces.Management;
|
2025-09-09 15:28:07 +08:00
|
|
|
|
|
|
|
|
public interface IMqttManagementService
|
|
|
|
|
{
|
2025-10-06 19:32:45 +08:00
|
|
|
Task<MqttServer> CreateMqttServerAsync(MqttServer mqttServer);
|
2025-09-09 15:28:07 +08:00
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// 异步删除一个MQTT服务器。
|
|
|
|
|
/// </summary>
|
2025-10-05 12:11:04 +08:00
|
|
|
Task<bool> DeleteMqttServerAsync(int id);
|
|
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// 异步批量删除MQTT服务器。
|
|
|
|
|
/// </summary>
|
|
|
|
|
Task<bool> DeleteMqttServersAsync(List<int> ids);
|
2025-10-06 19:32:45 +08:00
|
|
|
Task<List<MqttServer>> GetAllMqttServersAsync();
|
|
|
|
|
Task<MqttServer> GetMqttServerByIdAsync(int id);
|
|
|
|
|
Task<int> UpdateMqttServerAsync(MqttServer mqttServer);
|
|
|
|
|
Task<int> UpdateMqttServersAsync(List<MqttServer> mqttServers);
|
2025-10-18 17:59:21 +08:00
|
|
|
|
|
|
|
|
/// <summary>
|
|
|
|
|
/// 异步加载所有MQTT服务器数据到内存中。
|
|
|
|
|
/// </summary>
|
|
|
|
|
Task LoadAllMqttServersAsync();
|
2025-09-09 15:28:07 +08:00
|
|
|
}
|