namespace StockSharp.Messages;
///
/// User request message (uses as a subscribe/unsubscribe in outgoing case, confirmation event in incoming case).
///
[DataContract]
[Serializable]
public class UserRequestMessage : BaseRequestMessage
{
///
/// Login.
///
[DataMember]
[Display(
ResourceType = typeof(LocalizedStrings),
Name = LocalizedStrings.LoginKey,
Description = LocalizedStrings.LoginKey + LocalizedStrings.Dot,
GroupName = LocalizedStrings.GeneralKey,
Order = 0)]
public string Login { get; set; }
///
/// Identifier.
///
[DataMember]
public long? Id { get; set; }
///
public override DataType DataType => DataType.Users;
///
/// Initializes a new instance of the .
///
public UserRequestMessage()
: base(MessageTypes.UserRequest)
{
}
///
/// Create a copy of .
///
/// Copy.
public override Message Clone()
{
return CopyTo(new UserRequestMessage());
}
///
/// Copy the message into the .
///
/// The object, to which copied information.
/// The object, to which copied information.
protected UserRequestMessage CopyTo(UserRequestMessage destination)
{
base.CopyTo(destination);
destination.Login = Login;
destination.Id = Id;
return destination;
}
///
public override string ToString()
{
return base.ToString() + $",User={Login}/{Id}";
}
}