1
0
mirror of synced 2024-12-19 01:35:53 +01:00
GC-local-server-rewrite/Application/Game/Card/Read/ReadGetMessageQuery.cs
2023-02-17 00:38:01 +08:00

21 lines
659 B
C#

namespace Application.Game.Card.Read;
public record ReadGetMessageQuery(long CardId) : IRequestWrapper<string>;
public class ReadGetMessageQueryHandler : RequestHandlerBase<ReadGetMessageQuery, string>
{
private const string GET_MESSAGE_XPATH = "/root/get_message";
public ReadGetMessageQueryHandler(ICardDependencyAggregate aggregate) : base(aggregate)
{
}
public override Task<ServiceResult<string>> Handle(ReadGetMessageQuery request, CancellationToken cancellationToken)
{
var result = new object().SerializeCardData(GET_MESSAGE_XPATH);
return Task.FromResult(new ServiceResult<string>(result));
}
}