ComparativeFetchMixin
Auto-generated from the @jbrowse/mobx-state-tree model in the source — see the developer guide for concepts. Built into JBrowse core. View source.
The fetch foundation of the two comparative displays (LinearSyntenyDisplay,
DotplotDisplay): KeyedFetchMixin — FetchMixin's rotation, loading flag,
error, status, durable cancel and retry, plus the currentFetchKey /
loadedFetchKey freshness pair the LGV global family runs on — and, on top,
the two-way loading answer a shared canvas wants — loading off the
fetchLanded hook, refetching off isLoading — and the one-shot
reversed-assembly flag.
Until 2026-09 this was SyntenyFetchStateMixin, a second spelling of every
FetchMixin member the overlay reads — fetching for isLoading, its own
reloadCounter / fetchCanceled / reload / cancelFetchByUser, a stop
handed back from the installer because the rotation lived there — kept apart
on the grounds ADR-054 gives and ADR-105 retires. error kept the four flags
below out of that mixin: it is a BaseDisplay volatile the flags read, and declaring a second one to make them type-check is the ADR-041
hazard. FetchMixin is the one declaration site that already wins that
compose, so composing it lets the flags be getters here.
loading and refetching are different questions, and the difference
decides whether the user gets a full overlay or a corner chip
(ComparativeFetchStatus). displayPhase stays per display — it reads the
shared canvas's surfaceReadiness, which each view publishes differently —
through comparativeDisplayPhase.
Each section ends with the members a composed model contributes, linked to the page that documents them.
Volatiles
| Member | Description |
|---|---|
assembliesSwappedboolean | Set once at view load by a refName-comparison check, independent of the per-render fetch, so it never re-fires or misfires on zoom. Surfaces through each display's warnings. |
10 inherited volatiles from 2 models
From KeyedFetchMixin: loadedFetchKey
From FetchMixin: activeSignal, fetchGeneration, reloadCounter, statusWindow, error, statusMessage, statusProgress, fetchCanceled, fetchRotation
Getters
| Member | Description |
|---|---|
fetchLandedboolean | Overridable hook (default false): a fetch has completed and data is present, even if it mapped zero features. Not a feature-count test — an empty-but-finished fetch has landed, or an empty plot spins its overlay forever. Each display answers off its own payload field, which survives a reload() where loadedFetchKey does not, so a retry shows the corner chip rather than the full overlay.Default false is the strict answer — a display that forgets the override shows its first-load overlay forever (diagnosable) rather than reporting done over an empty plot. |
hasDrawableboolean | Overridable hook: the display holds something an SVG export can draw. Defaults to fetchLanded; the dotplot answers with its instance geometry rather than its geometry computed, because svgReady is polled outside any reactive context and a geometry read there recolors every segment per poll. |
loadingboolean | First load, nothing on screen yet: drives the full striped overlay. Deliberately not && isLoading, which would blink the overlay off during the pre-fetch debounce gap. Excludes error so error UI and loading UI never show at once, and fetchInert so a display that will never fetch rests instead of spinning on data that is not coming. |
refetchingboolean | A fetch is running over a stale plot still on screen (zoom, reorder, pan past the buffer): drives a corner indicator rather than the full overlay, so a viewport change does not mask what is drawn. |
svgReadyboolean | Off-screen SVG export gate, the shared computeSvgReady policy every display runs. Neither comparative display has a regionTooLarge state (LOD gates the fetch, not region size). fetchInert is the extra terminal, so an export cannot hang on data the autorun will never fetch, and fetchCanceled is terminal for the same reason: durable until Retry, and an export presses nothing. The data half waits out an in-flight same-key retry (!refetching) and a stale plot (dataCurrent). |
10 inherited getters from 2 models
From KeyedFetchMixin: viewSignature, dataSuperseded, currentFetchKey, dataCurrent
From FetchMixin: isLoading, isLoadingOrCanceled, fetchInert, awaitingPrerequisite, awaitingDependentData, settingsFetchInputs
Actions
| Member | Description |
|---|---|
setAssembliesSwapped(arg: boolean) => void |
12 inherited actions from 2 models
From KeyedFetchMixin: commitFetchResult, reload
From FetchMixin: setError, setStatusMessage, stopActiveFetch, openStatusStream, cancelFetch, cancelFetchByUser, beforeDestroy, beginFetch, endFetch, runFetch