示例#1
0
 public ChatData(string userFrom, AppConfig onlineUsers, CommunicationWithDB db)
 {
     this.UserFrom    = userFrom;
     this.Usernames   = db.GetAllUsernames(userFrom);
     this.UserFromId  = db.GetUserId(userFrom);
     this.OnlineUsers = onlineUsers;
 }
示例#2
0
 public UserChatData(string userFrom, string userTo, Services.AppConfig onlineUsers, CommunicationWithDB db) : base(userFrom, onlineUsers, db)
 {
     this.UserTo   = userTo;
     this.Messages = db.GetAllUserMessages(userFrom, userTo);
     this.UserToId = db.GetUserId(userTo);
 }