using CommunityToolkit.Mvvm.Messaging; using MultiTerm.Protocols.Network; namespace MultiTerm.Protocols.Udp; public partial class UdpProtocolSettingsViewModel : NetworkProtocolSettingsViewModel, IRecipient { public override Types.ProtocolType ProtocolType => Types.ProtocolType.Udp; public UdpProtocolSettingsViewModel(IMessenger messenger) : base(messenger) { // register for messages messenger.Register(this); } /// /// Sets the proprty to the resolved address from the message. /// /// void IRecipient.Receive(UdpConnectedMessage message) { this.ResolvedAddress = message.ResolvedAddress.ToString(); } }