Blender V4.3
blender::ComputeContext Class Referenceabstract

#include <BLI_compute_context.hh>

Inherited by blender::bke::ForeachGeometryElementZoneComputeContext, blender::bke::GroupNodeComputeContext, blender::bke::ModifierComputeContext, blender::bke::OperatorComputeContext, blender::bke::RepeatZoneComputeContext, and blender::bke::SimulationZoneComputeContext.

Public Member Functions

 ComputeContext (const char *static_type, const ComputeContext *parent)
 
virtual ~ComputeContext ()=default
 
const ComputeContextHashhash () const
 
const char * static_type () const
 
const ComputeContextparent () const
 
void print_stack (std::ostream &stream, StringRef name) const
 
virtual void print_current_in_line (std::ostream &stream) const =0
 

Protected Attributes

ComputeContextHash hash_
 

Friends

std::ostream & operator<< (std::ostream &stream, const ComputeContext &compute_context)
 

Detailed Description

Identifies the context in which a computation happens. This context can be used to identify values logged during the computation. For more details, see the comment at the top of the file.

This class should be subclassed to implement specific contexts.

Definition at line 73 of file BLI_compute_context.hh.

Constructor & Destructor Documentation

◆ ComputeContext()

blender::ComputeContext::ComputeContext ( const char * static_type,
const ComputeContext * parent )
inline

Definition at line 92 of file BLI_compute_context.hh.

References hash_, and parent().

◆ ~ComputeContext()

virtual blender::ComputeContext::~ComputeContext ( )
virtualdefault

Member Function Documentation

◆ hash()

◆ parent()

◆ print_current_in_line()

virtual void blender::ComputeContext::print_current_in_line ( std::ostream & stream) const
pure virtual

Print information about this specific context. This has to be implemented by each subclass.

◆ print_stack()

◆ static_type()

const char * blender::ComputeContext::static_type ( ) const
inline

Definition at line 106 of file BLI_compute_context.hh.

Friends And Related Symbol Documentation

◆ operator<<

std::ostream & operator<< ( std::ostream & stream,
const ComputeContext & compute_context )
friend

Definition at line 50 of file compute_context.cc.

Member Data Documentation

◆ hash_


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