FeedQuery class
A query for retrieving and managing feed data from Stream Feeds.
Defines parameters for fetching activities, followers, following, and members for a specific feed. Supports filtering, pagination, and real-time updates.
Example
final query = FeedQuery(
fid: FeedId(group: 'user', id: 'john'),
activityFilter: Filter.equal(ActivitiesFilterField.type, 'post'),
activityLimit: 25,
watch: true,
);
- Available extensions
- Annotations
-
- @freezed
Constructors
-
FeedQuery({required FeedId fid, ActivitiesFilter? activityFilter, int? activityLimit, String? activityNext, String? activityPrevious, FeedInputData? data, Map<
String, Object> ? externalRanking, int? followerLimit, int? followingLimit, Map<String, double> ? interestWeights, int? memberLimit, String? view, bool watch = true}) -
const
Properties
- activityFilter → ActivitiesFilter?
-
Filter criteria for activities in the feed.
final
- activityLimit → int?
-
The maximum number of activities to retrieve.
final
- activityNext → String?
-
The next page cursor for activity pagination.
final
- activityPrevious → String?
-
The previous page cursor for activity pagination.
final
-
copyWith
→ $FeedQueryCopyWith<
FeedQuery> -
Create a copy of FeedQuery
with the given fields replaced by the non-null parameter values.
no setterinherited
- data → FeedInputData?
-
Additional data to associate with the feed.
final
-
externalRanking
→ Map<
String, Object> ? -
Additional data used for ranking activities in the feed.
final
- fid → FeedId
-
The unique identifier for the feed.
final
- followerLimit → int?
-
The maximum number of followers to retrieve.
final
- followingLimit → int?
-
The maximum number of following users to retrieve.
final
- hashCode → int
-
The hash code for this object.
no setterinherited
-
interestWeights
→ Map<
String, double> ? -
Weights for different interests to influence activity ranking.
final
- memberLimit → int?
-
The maximum number of feed members to retrieve.
final
- runtimeType → Type
-
A representation of the runtime type of the object.
no setterinherited
- view → String?
-
Overwrite the default ranking or aggregation logic for this feed (for example: good for split testing).
final
- watch → bool
-
Whether to subscribe to web-socket events for this feed.
final
Methods
-
noSuchMethod(
Invocation invocation) → dynamic -
Invoked when a nonexistent method or property is accessed.
inherited
-
toRequest(
) → GetOrCreateFeedRequest -
Available on FeedQuery, provided by the FeedQueryRequest extension
-
toString(
) → String -
A string representation of this object.
inherited
Operators
-
operator ==(
Object other) → bool -
The equality operator.
inherited