Pulp 1.88.0
Cross-platform audio plugin framework
Loading...
Searching...
No Matches
pulp::playback::CompileInvalidationIndex Class Reference

Bundled reverse index for nested dependencies and compile-context readers. More...

#include <compile_context_registry.hpp>

Public Member Functions

std::span< const timeline::ItemId > subscribers (timeline::CompileContextKind kind) const noexcept
 Sorted, deduplicated track ids that declared a read of kind.
std::span< const timeline::ItemId > subscribers (timeline::ItemId owner_sequence, timeline::CompileContextKind kind) const noexcept
 Sorted, deduplicated root track ids that read kind from owner_sequence.
bool empty () const noexcept
bool valid () const noexcept
bool matches (const timeline::Project &project, timeline::ItemId root_sequence_id) const noexcept

Static Public Member Functions

static CompileInvalidationIndex build (const timeline::Project &project, timeline::ItemId sequence_id, const CompileContextRegistry &registry)

Friends

DirtyTrackSet resolve_dirty_tracks (const timeline::Project &project, timeline::ItemId root_sequence_id, const timeline::DirtySet &dirty, const CompileInvalidationIndex &index)
 Canonical translation from transaction dirtiness to root-track compiler dirtiness.

Detailed Description

Bundled reverse index for nested dependencies and compile-context readers.

Built atomically from one pinned snapshot, root, and registry, it turns "the chord lane changed" into an exact track set instead of a full recompile. Project structure identity and registry generation are checked in O(1); stale or mismatched indices fail closed. A context edit alone does not invalidate the index because editing a lane's contents does not change who reads it. Arrangement declarations remain indexed while a freeze or take lane is selected. Resolution filters them against the current snapshot, which keeps the index valid when playback later returns to the arrangement.

Member Function Documentation

◆ build()

CompileInvalidationIndex pulp::playback::CompileInvalidationIndex::build ( const timeline::Project & project,
timeline::ItemId sequence_id,
const CompileContextRegistry & registry )
static

◆ empty()

bool pulp::playback::CompileInvalidationIndex::empty ( ) const
noexcept

◆ matches()

bool pulp::playback::CompileInvalidationIndex::matches ( const timeline::Project & project,
timeline::ItemId root_sequence_id ) const
noexcept

◆ subscribers() [1/2]

std::span< const timeline::ItemId > pulp::playback::CompileInvalidationIndex::subscribers ( timeline::CompileContextKind kind) const
noexcept

Sorted, deduplicated track ids that declared a read of kind.

This aggregate query includes declarations reached through references.

◆ subscribers() [2/2]

std::span< const timeline::ItemId > pulp::playback::CompileInvalidationIndex::subscribers ( timeline::ItemId owner_sequence,
timeline::CompileContextKind kind ) const
noexcept

Sorted, deduplicated root track ids that read kind from owner_sequence.

◆ valid()

bool pulp::playback::CompileInvalidationIndex::valid ( ) const
noexcept

◆ resolve_dirty_tracks

DirtyTrackSet resolve_dirty_tracks ( const timeline::Project & project,
timeline::ItemId root_sequence_id,
const timeline::DirtySet & dirty,
const CompileInvalidationIndex & index )
friend

Canonical translation from transaction dirtiness to root-track compiler dirtiness.

This combines direct edits, transitive SequenceRef dependencies, and compile-context subscriptions in one fail-closed path.


The documentation for this class was generated from the following file: