module

Feed::Candidates

The candidate source.

The universe of posts eligible to be judged for a feed.

Instance methods

arrival_for(feed : Feed, object : ActivityPub::Object) : Time | Nil

Returns object's position in the feed, or nil if the object is not a candidate.

Source
candidates_for(feed : Feed, cursor : Int64 | Nil = nil, limit : Int32 | Nil = nil, floor_id : Int64 | Nil = nil) : Array(ActivityPub::Object)

Returns the feed's unjudged candidates, newest first.

cursor is the object id to scan down from; nil starts at the newest object. A caller that already knows the floor's id passes it as floor_id and the probe is skipped.

Source
floor_id(feed : Feed) : Int64 | Nil

Returns the id of the newest object at or below the feed's floor -- the bottom of the scan's window.

Source