15 lines
7.8 KiB
HTML
15 lines
7.8 KiB
HTML
<!DOCTYPE html><html lang="en"><head><meta charset="utf-8"><meta name="viewport" content="width=device-width, initial-scale=1.0"><meta name="generator" content="rustdoc"><meta name="description" content="Where a viewer is in a TV series."><title>jellytau_lib::repository::series_progress - Rust</title><script>if(window.location.protocol!=="file:")document.head.insertAdjacentHTML("beforeend","SourceSerif4-Regular-6b053e98.ttf.woff2,FiraSans-Italic-81dc35de.woff2,FiraSans-Regular-0fe48ade.woff2,FiraSans-MediumItalic-ccf7e434.woff2,FiraSans-Medium-e1aa3f0a.woff2,SourceCodePro-Regular-8badfe75.ttf.woff2,SourceCodePro-Semibold-aa29a496.ttf.woff2".split(",").map(f=>`<link rel="preload" as="font" type="font/woff2"href="../../../static.files/${f}">`).join(""))</script><link rel="stylesheet" href="../../../static.files/normalize-9960930a.css"><link rel="stylesheet" href="../../../static.files/rustdoc-17e0aaed.css"><meta name="rustdoc-vars" data-root-path="../../../" data-static-root-path="../../../static.files/" data-current-crate="jellytau_lib" data-themes="" data-resource-suffix="" data-rustdoc-version="1.97.1 (8bab26f4f 2026-07-14)" data-channel="1.97.1" data-search-js="search-fd9372ac.js" data-stringdex-js="stringdex-2da4960a.js" data-settings-js="settings-170eb4bf.js" ><script src="../../../static.files/storage-41dd4d93.js"></script><script defer src="../sidebar-items.js"></script><script defer src="../../../static.files/main-fcd733ba.js"></script><noscript><link rel="stylesheet" href="../../../static.files/noscript-f7c3ffd8.css"></noscript><link rel="alternate icon" type="image/png" href="../../../static.files/favicon-32x32-eab170b8.png"><link rel="icon" type="image/svg+xml" href="../../../static.files/favicon-044be391.svg"></head><body class="rustdoc mod"><a class="skip-main-content" href="#main-content">Skip to main content</a><!--[if lte IE 11]><div class="warning">This old browser is unsupported and will most likely display funky things.</div><![endif]--><rustdoc-topbar><h2><a href="#">Module series_progress</a></h2></rustdoc-topbar><nav class="sidebar"><div class="sidebar-crate"><h2><a href="../../../jellytau_lib/index.html">jellytau_<wbr>lib</a><span class="version">0.11.0</span></h2></div><div class="sidebar-elems"><section id="rustdoc-toc"><h2 class="location"><a href="#">Module series_<wbr>progress</a></h2><h3><a href="#constants">Module Items</a></h3><ul class="block"><li><a href="#constants" title="Constants">Constants</a></li><li><a href="#functions" title="Functions">Functions</a></li></ul></section><div id="rustdoc-modnav"><h2><a href="../index.html">In jellytau_<wbr>lib::<wbr>repository</a></h2></div></div></nav><div class="sidebar-resizer" title="Drag to resize sidebar"></div><main><div class="width-limiter"><section id="main-content" class="content" tabindex="-1"><div class="main-heading"><div class="rustdoc-breadcrumbs"><a href="../../index.html">jellytau_lib</a>::<wbr><a href="../index.html">repository</a></div><h1>Module <span>series_<wbr>progress</span> <button id="copy-path" title="Copy item path to clipboard">Copy item path</button></h1><rustdoc-toolbar></rustdoc-toolbar><span class="sub-heading"><a class="src" href="../../../src/jellytau_lib/repository/series_progress.rs.html#1-497">Source</a> </span></div><details class="toggle top-doc" open><summary class="hideme"><span>Expand description</span></summary><div class="docblock"><p>Where a viewer is in a TV series.</p>
|
||
<p>This is domain policy, not presentation: it encodes what Jellyfin’s user-data
|
||
means (“in progress”, “played”) and what Jellyfin’s season numbering means
|
||
(season 0 is specials). The frontend asks for <em>the</em> current episode and
|
||
renders it; it does not get to decide what “current” means.</p>
|
||
<p>Split into a pure half (<code>pick_current_episode</code>, <code>sort_series_order</code>) and an
|
||
I/O half (<code>fetch_series_episodes</code>, <code>resolve_current_episode</code>) so the policy
|
||
can be unit-tested without standing up a repository.</p>
|
||
<p>TRACES: UR-062 | DR-101</p>
|
||
</div></details><h2 id="constants" class="section-header">Constants<a href="#constants" class="anchor">§</a></h2><dl class="item-table"><dt><a class="constant" href="constant.MAX_PROGRESS_FRACTION.html" title="constant jellytau_lib::repository::series_progress::MAX_PROGRESS_FRACTION">MAX_<wbr>PROGRESS_<wbr>FRACTION</a><span title="Restricted Visibility"> 🔒</span> </dt><dd>Above this fraction watched, an episode is effectively finished; resuming it
|
||
would drop the viewer into the closing credits.</dd><dt><a class="constant" href="constant.MIN_PROGRESS_FRACTION.html" title="constant jellytau_lib::repository::series_progress::MIN_PROGRESS_FRACTION">MIN_<wbr>PROGRESS_<wbr>FRACTION</a><span title="Restricted Visibility"> 🔒</span> </dt><dd>Below this fraction watched, a position is a false start rather than
|
||
progress — the same threshold the resume dialog uses.</dd><dt><a class="constant" href="constant.SPECIALS_SEASON.html" title="constant jellytau_lib::repository::series_progress::SPECIALS_SEASON">SPECIALS_<wbr>SEASON</a><span title="Restricted Visibility"> 🔒</span> </dt><dd>Jellyfin files specials under season 0.</dd></dl><h2 id="functions" class="section-header">Functions<a href="#functions" class="anchor">§</a></h2><dl class="item-table"><dt><a class="fn" href="fn.belongs_to_series.html" title="fn jellytau_lib::repository::series_progress::belongs_to_series">belongs_<wbr>to_<wbr>series</a><span title="Restricted Visibility"> 🔒</span> </dt><dt><a class="fn" href="fn.fetch_series_episodes.html" title="fn jellytau_lib::repository::series_progress::fetch_series_episodes">fetch_<wbr>series_<wbr>episodes</a></dt><dd>Every episode of a series, in series order.</dd><dt><a class="fn" href="fn.is_episode.html" title="fn jellytau_lib::repository::series_progress::is_episode">is_<wbr>episode</a><span title="Restricted Visibility"> 🔒</span> </dt><dt><a class="fn" href="fn.is_in_progress.html" title="fn jellytau_lib::repository::series_progress::is_in_progress">is_<wbr>in_<wbr>progress</a><span title="Restricted Visibility"> 🔒</span> </dt><dd>Is this episode genuinely part-watched (not a false start, not finished)?</dd><dt><a class="fn" href="fn.is_played.html" title="fn jellytau_lib::repository::series_progress::is_played">is_<wbr>played</a><span title="Restricted Visibility"> 🔒</span> </dt><dt><a class="fn" href="fn.is_season.html" title="fn jellytau_lib::repository::series_progress::is_season">is_<wbr>season</a><span title="Restricted Visibility"> 🔒</span> </dt><dt><a class="fn" href="fn.list_options.html" title="fn jellytau_lib::repository::series_progress::list_options">list_<wbr>options</a><span title="Restricted Visibility"> 🔒</span> </dt><dt><a class="fn" href="fn.pick_current_episode.html" title="fn jellytau_lib::repository::series_progress::pick_current_episode">pick_<wbr>current_<wbr>episode</a></dt><dd>The episode a viewer should land on when they open <code>series_id</code>.</dd><dt><a class="fn" href="fn.resolve_current_episode.html" title="fn jellytau_lib::repository::series_progress::resolve_current_episode">resolve_<wbr>current_<wbr>episode</a></dt><dd>Resolve the current episode, fetching everything the policy needs.</dd><dt><a class="fn" href="fn.season_rank.html" title="fn jellytau_lib::repository::series_progress::season_rank">season_<wbr>rank</a><span title="Restricted Visibility"> 🔒</span> </dt><dd>Sort key for a season number. Specials sort <em>after</em> every numbered season:
|
||
a viewer works through S1, S2, … and only then the extras, so season 0 must
|
||
not lead just because <code>0 < 1</code>.</dd><dt><a class="fn" href="fn.sort_series_order.html" title="fn jellytau_lib::repository::series_progress::sort_series_order">sort_<wbr>series_<wbr>order</a></dt><dd>Order episodes as the series is watched: season ascending, then episode,
|
||
specials last.</dd></dl></section></div></main></body></html> |