Example #1
0
 public RoomFilter(
     bool includeLeave = false,
     [CanBeNull] IReadOnlyCollection <string> rooms    = null,
     [CanBeNull] IReadOnlyCollection <string> notRooms = null,
     [CanBeNull] RoomEventFilter accountData           = null,
     [CanBeNull] RoomEventFilter ephemeral             = null,
     [CanBeNull] RoomEventFilter state    = null,
     [CanBeNull] RoomEventFilter timeline = null)
     : this()
 {
     IncludeLeave = includeLeave;
     Rooms        = rooms;
     NotRooms     = notRooms;
     AccountData  = accountData;
     Ephemeral    = ephemeral;
     State        = state;
     Timeline     = timeline;
 }
Example #2
0
 /// <summary>
 /// Initializes a new instance of the <see cref="RoomFilter" /> structure.
 /// </summary>
 /// <param name="includeLeave">A value indicating whether left rooms should be included.</param>
 /// <param name="rooms">A collection of room IDs to include.</param>
 /// <param name="notRooms">A collection of room IDs to exclude.</param>
 /// <param name="accountData">An event filter to apply to account data.</param>
 /// <param name="ephemeral">An event filter to apply to ephemeral events.</param>
 /// <param name="state">An event filter to apply to state events.</param>
 /// <param name="timeline">An event filter to apply to timeline events.</param>
 public RoomFilter(
     bool includeLeave = false,
     [CanBeNull] IEnumerable <string> rooms    = null,
     [CanBeNull] IEnumerable <string> notRooms = null,
     [CanBeNull] RoomEventFilter accountData   = null,
     [CanBeNull] RoomEventFilter ephemeral     = null,
     [CanBeNull] RoomEventFilter state         = null,
     [CanBeNull] RoomEventFilter timeline      = null)
     : this(
         includeLeave,
         rooms?.ToList().AsReadOnly(),
         notRooms?.ToList().AsReadOnly(),
         accountData,
         ephemeral,
         state,
         timeline)
 {
 }