namespace ZB.MOM.WW.MxGateway.Worker.MxAccess;
///
/// Operator identity an alarm acknowledgement authenticates as. The password
/// is a raw credential: it is passed to MXAccess AuthenticateUser only
/// and must never be logged or echoed.
///
public sealed class AlarmAckOperator
{
/// Gets or sets the operator user name.
public string UserName { get; set; } = string.Empty;
/// Gets or sets the optional domain for OS-authenticated galaxies.
public string Domain { get; set; } = string.Empty;
/// Gets or sets the operator password (credential-sensitive).
public string Password { get; set; } = string.Empty;
/// Gets the user string passed to AuthenticateUser: Domain\UserName when a domain is set.
public string VerifyUser => string.IsNullOrEmpty(Domain) ? UserName : Domain + "\\" + UserName;
///
public override string ToString() => "AlarmAckOperator(" + VerifyUser + ")";
}