KiCad PCB EDA Suite
Loading...
Searching...
No Matches
SCH_CONNECTIVITY::COMPONENT_CACHE< VALUE > Class Template Reference

Cache current component evaluations by exact node/version identity, within one stratum and key session. More...

#include <conn_component_cache.h>

Classes

struct  ENTRY
 

Public Member Functions

 COMPONENT_CACHE (CACHE_VERSIONS &aVersions)
 
 COMPONENT_CACHE (const COMPONENT_CACHE &)=delete
 
COMPONENT_CACHEoperator= (const COMPONENT_CACHE &)=delete
 
template<typename EVALUATE>
void UpdateBatch (std::span< const PARTITION > aPartitions, EVALUATE &&aEvaluate)
 Main-thread update that evaluates only cache misses, returning values in the supplied partition order.
 
const auto & Entries () const
 
void Clear ()
 

Private Attributes

CACHE_VERSIONSm_versions
 
std::vector< std::unique_ptr< const ENTRY > > m_entries
 

Detailed Description

template<typename VALUE>
class SCH_CONNECTIVITY::COMPONENT_CACHE< VALUE >

Cache current component evaluations by exact node/version identity, within one stratum and key session.

See also
Modification

Definition at line 39 of file conn_component_cache.h.

Constructor & Destructor Documentation

◆ COMPONENT_CACHE() [1/2]

template<typename VALUE>
SCH_CONNECTIVITY::COMPONENT_CACHE< VALUE >::COMPONENT_CACHE ( CACHE_VERSIONS & aVersions)
inlineexplicit

Definition at line 49 of file conn_component_cache.h.

References m_versions.

Referenced by COMPONENT_CACHE(), and operator=().

◆ COMPONENT_CACHE() [2/2]

template<typename VALUE>
SCH_CONNECTIVITY::COMPONENT_CACHE< VALUE >::COMPONENT_CACHE ( const COMPONENT_CACHE< VALUE > & )
delete

References COMPONENT_CACHE().

Member Function Documentation

◆ Clear()

template<typename VALUE>
void SCH_CONNECTIVITY::COMPONENT_CACHE< VALUE >::Clear ( )
inline

Definition at line 113 of file conn_component_cache.h.

References m_entries.

◆ Entries()

template<typename VALUE>
const auto & SCH_CONNECTIVITY::COMPONENT_CACHE< VALUE >::Entries ( ) const
inline

◆ operator=()

template<typename VALUE>
COMPONENT_CACHE & SCH_CONNECTIVITY::COMPONENT_CACHE< VALUE >::operator= ( const COMPONENT_CACHE< VALUE > & )
delete

References COMPONENT_CACHE().

◆ UpdateBatch()

template<typename VALUE>
template<typename EVALUATE>
void SCH_CONNECTIVITY::COMPONENT_CACHE< VALUE >::UpdateBatch ( std::span< const PARTITION > aPartitions,
EVALUATE && aEvaluate )
inline

Main-thread update that evaluates only cache misses, returning values in the supplied partition order.

The evaluator must not mutate this cache or its input tables. Versions must cover every input read by the evaluator. Entries follow distinct input partitions. Reacquire references after UpdateBatch/Clear; use versions rather than addresses for change detection.

Definition at line 63 of file conn_component_cache.h.

References end, SCH_CONNECTIVITY::PARTITION::hash, m_entries, and m_versions.

Member Data Documentation

◆ m_entries

template<typename VALUE>
std::vector<std::unique_ptr<const ENTRY> > SCH_CONNECTIVITY::COMPONENT_CACHE< VALUE >::m_entries
private

Definition at line 117 of file conn_component_cache.h.

Referenced by Clear(), Entries(), and UpdateBatch().

◆ m_versions

template<typename VALUE>
CACHE_VERSIONS& SCH_CONNECTIVITY::COMPONENT_CACHE< VALUE >::m_versions
private

Definition at line 116 of file conn_component_cache.h.

Referenced by COMPONENT_CACHE(), and UpdateBatch().


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