public void SetData(int senderId, SendrType sender, string text) { byte[] textdata = Encoding.UTF8.GetBytes(text); dataLenght = textdata.Length; Array.Copy(textdata, data, dataLenght); this.senderId = senderId; sendrType = sender; }
public MessageChat(int senderId, SendrType sender, string text) { SetData(senderId, sender, text); }