Пример #1
0
        public override object createChatViewModel(EViewModel viewModelName, IChatRoomViewModel mainChatViewModel)
        {
            switch (viewModelName)
            {
            case EViewModel.CHATDISCUSSION:
                return(new DiscussionViewModel(mainChatViewModel));

            case EViewModel.CHATMESSAGE:
                return(new MessageViewModel(mainChatViewModel));
            }
            return(null);
        }
Пример #2
0
 public MessageViewModel(IChatRoomViewModel mainChatRoom) : this()
 {
     _mainChatRoom = mainChatRoom;
     this._page    = _mainChatRoom.navigation;
 }
Пример #3
0
 public virtual object createChatViewModel(EViewModel viewModelName, IChatRoomViewModel mainChatViewModel)
 {
     throw new NotApplicableException("Cannot create chat view model for the targeted object!");
 }