The queue, the inbox and the playlists of a profile, and what the new episodes of a feed do to them.
The queue and the playlists are ordered collections of mind-meld, so the devices agree on their order, and a move never brings back an episode that another device took out. A playlist is kept beside the queue, and goes out as a list feed of the podcast namespace.
The queue, the inbox and the playlists of a profile, and what the new episodes of a feed do to them. The queue and the playlists are ordered collections of mind-meld, so the devices agree on their order, and a move never brings back an episode that another device took out. A playlist is kept beside the queue, and goes out as a list feed of the podcast namespace.
(add-to-playlist profile name id at)Put the episode id at the end of the playlist name of profile at
at, unless the playlist holds it.
Put the episode `id` at the end of the playlist `name` of `profile` at `at`, unless the playlist holds it.
(advance profile at)Drop the current episode from the queue of profile at at, so that the
next one is current.
Drop the current episode from the queue of `profile` at `at`, so that the next one is current.
(current profile)The episode id at the front of the queue of profile, or nil when it's
empty.
The episode id at the front of the queue of `profile`, or nil when it's empty.
(dequeue profile id at)Take the episode id out of the queue of profile at at, leaving a
tombstone, so that it outlives an older addition on another device.
Take the episode `id` out of the queue of `profile` at `at`, leaving a tombstone, so that it outlives an older addition on another device.
(dequeue-all profile ids at)Take the episodes ids out of the queue of profile at at with one
stamp, leaving tombstones, e.g. (queue profile) to clear it.
Take the episodes `ids` out of the queue of `profile` at `at` with one stamp, leaving tombstones, e.g. (queue profile) to clear it.
(dismiss profile id at)Take the episode id out of the inbox of profile at at, leaving a
tombstone.
Take the episode `id` out of the inbox of `profile` at `at`, leaving a tombstone.
(dismiss-all profile ids at)Take the episodes ids out of the inbox of profile at at with one
stamp, e.g. all of the inbox, leaving tombstones.
Take the episodes `ids` out of the inbox of `profile` at `at` with one stamp, e.g. all of the inbox, leaving tombstones.
(enqueue profile id at)Put the episode id at the end of the queue of profile at at, unless
it is in the queue.
Put the episode `id` at the end of the queue of `profile` at `at`, unless it is in the queue.
(enqueue-all profile ids at)Put the episodes ids in order at the end of the queue of profile at
at with one stamp, but for those that it holds, and take them out of
the inbox.
Put the episodes `ids` in order at the end of the queue of `profile` at `at` with one stamp, but for those that it holds, and take them out of the inbox.
(from-list-feed profile name feed at)Add the episodes of the list feed feed to the end of the playlist
name of profile at at, in the order of the feed.
Add the episodes of the list feed `feed` to the end of the playlist `name` of `profile` at `at`, in the order of the feed.
(in-inbox? profile id)Whether the episode id is in the inbox of profile, and the listener
hasn't dismissed, queued or played it since it arrived.
Whether the episode `id` is in the inbox of `profile`, and the listener hasn't dismissed, queued or played it since it arrived.
(inbox profile)The episode ids in the inbox of profile, the latest to arrive first.
The episode ids in the inbox of `profile`, the latest to arrive first.
(move profile id index at)Move the queued episode id to position index of the queue of profile
at at. An index that isn't whole is rounded down, and NaN counts as 0.
Move the queued episode `id` to position `index` of the queue of `profile` at `at`. An index that isn't whole is rounded down, and NaN counts as 0.
(move-in-playlist profile name id index at)Move the episode id to position index of the playlist name of
profile at at.
Move the episode `id` to position `index` of the playlist `name` of `profile` at `at`.
(play-next profile id at)Put the episode id right after the current episode of profile at at,
moving it there when it's queued, or to the front of an empty queue.
Put the episode `id` right after the current episode of `profile` at `at`, moving it there when it's queued, or to the front of an empty queue.
(playlist profile name)The episode ids in the playlist name of profile, in order. A playlist
is kept beside the queue, so to play it, queue its episodes.
The episode ids in the playlist `name` of `profile`, in order. A playlist is kept beside the queue, so to play it, queue its episodes.
(playlists profile)The episode ids of each playlist of profile, by name, leaving out the
playlists without episodes.
The episode ids of each playlist of `profile`, by name, leaving out the playlists without episodes.
(queue profile)The episode ids queued in profile, the current one first.
The episode ids queued in `profile`, the current one first.
(queued? profile id)Whether the episode id is in the queue of profile.
Whether the episode `id` is in the queue of `profile`.
(refresh profile url before after at)(refresh profile url before after at {:keys [join-pred] :as opts})Note in profile at at a new parse after of the feed at url, which
was before, with the opts of feed/new-episodes and :join-pred. The
result is a map of the new :profile and the episode ids that
feed/new-episodes gives: those :added, :backfilled and :renamed.
The new episodes join the queue with :auto-queue? in the settings of a live subscription, at its end or right after the current episode, the newest :auto-queue-max of them when it's set. The others join the inbox with :inbox?. With :join-pred, a predicate of the feed and an item, e.g. of criteria/where, only the episodes that meet it join either. An episode that's already in the profile stays as the listener left it. A renamed episode takes its state along, as profile/rename-episode moves it, written by this device for the listener.
Note in `profile` at `at` a new parse `after` of the feed at `url`, which was `before`, with the `opts` of feed/new-episodes and :join-pred. The result is a map of the new :profile and the episode ids that feed/new-episodes gives: those :added, :backfilled and :renamed. The new episodes join the queue with :auto-queue? in the settings of a live subscription, at its end or right after the current episode, the newest :auto-queue-max of them when it's set. The others join the inbox with :inbox?. With :join-pred, a predicate of the feed and an item, e.g. of criteria/where, only the episodes that meet it join either. An episode that's already in the profile stays as the listener left it. A renamed episode takes its state along, as profile/rename-episode moves it, written by this device for the listener.
(remove-from-playlist profile name id at)Take the episode id out of the playlist name of profile at at,
leaving a tombstone.
Take the episode `id` out of the playlist `name` of `profile` at `at`, leaving a tombstone.
(rename-playlist profile from to at)Move the episodes of the playlist from of profile to the end of the
playlist to at at, or delete the playlist when to is nil.
The episodes keep their order, and an episode that both playlists hold
stays where to has it.
Move the episodes of the playlist `from` of `profile` to the end of the playlist `to` at `at`, or delete the playlist when `to` is nil. The episodes keep their order, and an episode that both playlists hold stays where `to` has it.
(to-list-feed profile name)(to-list-feed
profile
name
{:keys [url link description medium] :or {medium "podcastL"} :as opts})The playlist name of profile as a list feed of the podcast namespace,
with the opts below.
It's a channel of the medium podcastL, whose remote items point to the
episodes in order. The opts give what a feed needs and a playlist
lacks:
The URLs of the feeds go out without credentials.
The playlist `name` of `profile` as a list feed of the podcast namespace, with the `opts` below. It's a channel of the medium podcastL, whose remote items point to the episodes in order. The `opts` give what a feed needs and a playlist lacks: - :url, where the feed is published, which gives its podcast:guid - :link, a page about the list, the URL by default, which RSS 2.0 requires - :description, the name by default - :medium, another medium, such as mixed The URLs of the feeds go out without credentials.
cljdoc builds & hosts documentation for Clojure/Script libraries
| Ctrl+k | Jump to recent docs |
| ← | Move to previous article |
| → | Move to next article |
| Ctrl+/ | Jump to the search field |