コード例 #1
0
        public bool TryGetPollForRoom(int roomId, out RoomPoll roomPoll)
        {
            roomPoll = null;
            if (this._polls.Count(x => x.Value.RoomId == roomId) == 0)
            {
                return(false);
            }

            return(this._polls.TryGetValue(this._polls.FirstOrDefault(x => x.Value.RoomId == roomId).Value.Id, out roomPoll));
        }
コード例 #2
0
        public bool TryGetPollForHotel(int id, out RoomPoll hotelPoll)
        {
            hotelPoll = null;
            if (this._polls.Count(x => x.Value.Id == id) == 0)
            {
                return(false);
            }

            return(this._polls.TryGetValue(this._polls.FirstOrDefault(x => x.Value.Id == id).Value.Id, out hotelPoll));
        }
コード例 #3
0
 public bool TryGetPoll(int pollId, out RoomPoll roomPoll)
 {
     return(this._polls.TryGetValue(pollId, out roomPoll));
 }