---
name: "sc_RefBase"
section: "3"
platform: "linux"
package: "libsc-doc"
version: "2.3.1-22"
release: "Debian 12 (Bookworm)"
platforms: ["linux"]
url: "https://new.carta.tech/sc_RefBase"
---

# sc\_RefBase(3)

Provides a few utility routines common to all Ref template instantiations.

## NAME

sc::RefBase - Provides a few utility routines common to all **Ref** template instantiations.

## SYNOPSIS

`#include <ref.h>`

Inherited by **sc::Ref\< DiagSCMatrix \>**, **sc::Ref\< SCDimension \>**, **sc::Ref\< SCMatrix \>**, **sc::Ref\< SCVector \>**, **sc::Ref\< SymmSCMatrix \>**, **sc::Ref\< sc::ThreadLock \>**, **sc::Ref\< sc::Wavefunction \>**, **sc::Ref\< sc::KeyVal \>**, **sc::Ref\< sc::AtomInfo \>**, **sc::Ref\< sc::Molecule \>**, **sc::Ref\< sc::SCMatrixKit \>**, **sc::Ref\< sc::MessageGrp \>**, **sc::Ref\< sc::TriangulatedImplicitSurface \>**, **sc::Ref\< sc::BEMSolvent \>**, **sc::Ref\< sc::GaussianBasisSet \>**, **sc::Ref\< sc::DenIntegrator \>**, **sc::Ref\< sc::DenFunctional \>**, **sc::Ref\< sc::PointGroup \>**, **sc::Ref\< sc::MemoryGrp \>**, **sc::Ref\< sc::TwoBodyInt \>**, **sc::Ref\< sc::TwoBodyDerivInt \>**, **sc::Ref\< sc::RegionTimer \>**, **sc::Ref\< sc::SCExtrapData \>**, **sc::Ref\< sc::SCExtrapError \>**, **sc::Ref\< sc::BatchElectronDensity \>**, **sc::Ref\< sc::ThreadGrp \>**, **sc::Ref\< sc::Int1eV3 \>**, **sc::Ref\< sc::DipoleData \>**, **sc::Ref\< sc::SCMatrixBlockList \>**, **sc::Ref\< sc::HessianUpdate \>**, **sc::Ref\< sc::Vertex \>**, **sc::Ref\< sc::EfieldDotVectorData \>**, **sc::Ref\< sc::ShellPairsCints \>**, **sc::Ref\< sc::FJT \>**, **sc::Ref\< sc::MolecularEnergy \>**, **sc::Ref\< sc::MolecularCoor \>**, **sc::Ref\< sc::Volume \>**, **sc::Ref\< sc::PointChargeData \>**, **sc::Ref\< sc::IntegralStorer \>**, **sc::Ref\< sc::IntCoorGen \>**, **sc::Ref\< sc::SetIntCoor \>**, **sc::Ref\< sc::IntCoor \>**, **sc::Ref\< sc::DescribedClass \>**, **sc::Ref\< sc::Function \>**, **sc::Ref\< sc::SCMatrixDiagBlock \>**, **sc::Ref\< sc::Integral \>**, **sc::Ref\< sc::SCMatrixRectBlock \>**, **sc::Ref\< sc::SCVectorSimpleBlock \>**, **sc::Ref\< sc::SCMatrixLTriBlock \>**, **sc::Ref\< sc::SCF \>**, **sc::Ref\< sc::R12IntEval \>**, **sc::Ref\< sc::MP2R12Energy \>**, **sc::Ref\< sc::SCVector \>**, **sc::Ref\< sc::TwoBodyGrid \>**, **sc::Ref\< sc::MOIndexSpace \>**, **sc::Ref\< sc::MachineTopology \>**, **sc::Ref\< sc::RenderedMolecule \>**, **sc::Ref\< sc::MolecularFrequencies \>**, **sc::Ref\< sc::MolecularHessian \>**, **sc::Ref\< sc::Units \>**, **sc::Ref\< sc::OneBodyIntIter \>**, **sc::Ref\< sc::Int1eCCA \>**, **sc::Ref\< sc::Int1eCints \>**, **sc::Ref\< sc::OneBodyInt \>**, **sc::Ref\< sc::SOBasis \>**, **sc::Ref\< sc::Convergence \>**, **sc::Ref\< sc::OneBodyWavefunction \>**, **sc::Ref\< sc::LSDACFunctional \>**, **sc::Ref\< sc::PsiSCF \>**, **sc::Ref\< sc::PsiInput \>**, **sc::Ref\< sc::PsiFile11 \>**, **sc::Ref\< sc::PsiExEnv \>**, **sc::Ref\< sc::LineOpt \>**, **sc::Ref\< sc::R12IntEvalInfo \>**, **sc::Ref\< sc::R12Amplitudes \>**, **sc::Ref\< sc::MOIntsTransformFactory \>**, **sc::Ref\< sc::IntegrationWeight \>**, **sc::Ref\< sc::RadialIntegrator \>**, **sc::Ref\< sc::AngularIntegrator \>**, **sc::Ref\< sc::Material \>**, **sc::Ref\< sc::Appearance \>**, **sc::Ref\< sc::Transform \>**, **sc::Ref\< sc::MoleculeColorizer \>**, **sc::Ref\< sc::RenderedObject \>**, **sc::Ref\< sc::SCBlockInfo \>**, **sc::Ref\< sc::SelfConsistentExtrapolation \>**, **sc::Ref\< sc::AccumH \>**, **sc::Ref\< sc::SCMatrixSubblockIter \>**, **sc::Ref\< sc::SCMatrixBlock \>**, **sc::Ref\< sc::SavableState \>**, **sc::Ref\< sc::PrimPairsCints \>**, **sc::Ref\< sc::ShellPairCints \>**, **sc::Ref\< sc::PetiteList \>**, **sc::Ref\< sc::Edge \>**, **sc::Ref\< sc::TriInterpCoef \>**, **sc::Ref\< sc::TriangleIntegrator \>**, **sc::Ref\< sc::TriangulatedSurface \>**, **sc::Ref\< sc::Int2eCCA \>**, **sc::Ref\< sc::Int2eCints \>**, **sc::Ref\< sc::Int2eV3 \>**, **sc::Ref\< sc::R12IntsAcc \>**, **sc::Ref\< sc::TwoBodyMOIntsTransform \>**, **sc::Ref\< sc::OverlapOrthog \>**, and **sc::Ref\< T \>**.

### Public Member Functions

virtual **RefCount** \* **parentpointer** () const =0\
 Returns the **DescribedClass** pointer for the contained object.  void **require\_nonnull** () const\
 Requires that a nonnull reference is held.

### Protected Member Functions

void **warn** (const char \*msg) const\
 Print a warning message.  void **warn\_ref\_to\_stack** () const\
 Called when stack data is referenced.  void **warn\_skip\_stack\_delete** () const\
 Called when the deletion of stack data is skipped.  void **warn\_bad\_ref\_count** () const\
 Called when the reference count is corrupted.  void **ref\_info** (**RefCount** \*p, std::ostream &os) const\
 Print information about the reference.  void **ref\_info** (std::ostream &os) const\
 void **check\_pointer** () const\
 void **reference** (**RefCount** \*)\
 int **dereference** (**RefCount** \*)\

## Detailed Description

Provides a few utility routines common to all **Ref** template instantiations.

## Member Function Documentation

### virtual RefCount \* sc::RefBase::parentpointer () const` [pure virtual]`

Returns the **DescribedClass** pointer for the contained object.

Implemented in **sc::Ref\< T \>**, **sc::Ref\< DiagSCMatrix \>**, **sc::Ref\< SCDimension \>**, **sc::Ref\< SCMatrix \>**, **sc::Ref\< SCVector \>**, **sc::Ref\< SymmSCMatrix \>**, **sc::Ref\< sc::ThreadLock \>**, **sc::Ref\< sc::Wavefunction \>**, **sc::Ref\< sc::KeyVal \>**, **sc::Ref\< sc::AtomInfo \>**, **sc::Ref\< sc::Molecule \>**, **sc::Ref\< sc::SCMatrixKit \>**, **sc::Ref\< sc::MessageGrp \>**, **sc::Ref\< sc::TriangulatedImplicitSurface \>**, **sc::Ref\< sc::BEMSolvent \>**, **sc::Ref\< sc::GaussianBasisSet \>**, **sc::Ref\< sc::DenIntegrator \>**, **sc::Ref\< sc::DenFunctional \>**, **sc::Ref\< sc::PointGroup \>**, **sc::Ref\< sc::MemoryGrp \>**, **sc::Ref\< sc::TwoBodyInt \>**, **sc::Ref\< sc::TwoBodyDerivInt \>**, **sc::Ref\< sc::RegionTimer \>**, **sc::Ref\< sc::SCExtrapData \>**, **sc::Ref\< sc::SCExtrapError \>**, **sc::Ref\< sc::BatchElectronDensity \>**, **sc::Ref\< sc::ThreadGrp \>**, **sc::Ref\< sc::Int1eV3 \>**, **sc::Ref\< sc::DipoleData \>**, **sc::Ref\< sc::SCMatrixBlockList \>**, **sc::Ref\< sc::HessianUpdate \>**, **sc::Ref\< sc::Vertex \>**, **sc::Ref\< sc::EfieldDotVectorData \>**, **sc::Ref\< sc::ShellPairsCints \>**, **sc::Ref\< sc::FJT \>**, **sc::Ref\< sc::MolecularEnergy \>**, **sc::Ref\< sc::MolecularCoor \>**, **sc::Ref\< sc::Volume \>**, **sc::Ref\< sc::PointChargeData \>**, **sc::Ref\< sc::IntegralStorer \>**, **sc::Ref\< sc::IntCoorGen \>**, **sc::Ref\< sc::SetIntCoor \>**, **sc::Ref\< sc::IntCoor \>**, **sc::Ref\< sc::DescribedClass \>**, **sc::Ref\< sc::Function \>**, **sc::Ref\< sc::SCMatrixDiagBlock \>**, **sc::Ref\< sc::Integral \>**, **sc::Ref\< sc::SCMatrixRectBlock \>**, **sc::Ref\< sc::SCVectorSimpleBlock \>**, **sc::Ref\< sc::SCMatrixLTriBlock \>**, **sc::Ref\< sc::SCF \>**, **sc::Ref\< sc::R12IntEval \>**, **sc::Ref\< sc::MP2R12Energy \>**, **sc::Ref\< sc::SCVector \>**, **sc::Ref\< sc::TwoBodyGrid \>**, **sc::Ref\< sc::MOIndexSpace \>**, **sc::Ref\< sc::MachineTopology \>**, **sc::Ref\< sc::RenderedMolecule \>**, **sc::Ref\< sc::MolecularFrequencies \>**, **sc::Ref\< sc::MolecularHessian \>**, **sc::Ref\< sc::Units \>**, **sc::Ref\< sc::OneBodyIntIter \>**, **sc::Ref\< sc::Int1eCCA \>**, **sc::Ref\< sc::Int1eCints \>**, **sc::Ref\< sc::OneBodyInt \>**, **sc::Ref\< sc::SOBasis \>**, **sc::Ref\< sc::Convergence \>**, **sc::Ref\< sc::OneBodyWavefunction \>**, **sc::Ref\< sc::LSDACFunctional \>**, **sc::Ref\< sc::PsiSCF \>**, **sc::Ref\< sc::PsiInput \>**, **sc::Ref\< sc::PsiFile11 \>**, **sc::Ref\< sc::PsiExEnv \>**, **sc::Ref\< sc::LineOpt \>**, **sc::Ref\< sc::R12IntEvalInfo \>**, **sc::Ref\< sc::R12Amplitudes \>**, **sc::Ref\< sc::MOIntsTransformFactory \>**, **sc::Ref\< sc::IntegrationWeight \>**, **sc::Ref\< sc::RadialIntegrator \>**, **sc::Ref\< sc::AngularIntegrator \>**, **sc::Ref\< sc::Material \>**, **sc::Ref\< sc::Appearance \>**, **sc::Ref\< sc::Transform \>**, **sc::Ref\< sc::MoleculeColorizer \>**, **sc::Ref\< sc::RenderedObject \>**, **sc::Ref\< sc::SCBlockInfo \>**, **sc::Ref\< sc::SelfConsistentExtrapolation \>**, **sc::Ref\< sc::AccumH \>**, **sc::Ref\< sc::SCMatrixSubblockIter \>**, **sc::Ref\< sc::SCMatrixBlock \>**, **sc::Ref\< sc::SavableState \>**, **sc::Ref\< sc::PrimPairsCints \>**, **sc::Ref\< sc::ShellPairCints \>**, **sc::Ref\< sc::PetiteList \>**, **sc::Ref\< sc::Edge \>**, **sc::Ref\< sc::TriInterpCoef \>**, **sc::Ref\< sc::TriangleIntegrator \>**, **sc::Ref\< sc::TriangulatedSurface \>**, **sc::Ref\< sc::Int2eCCA \>**, **sc::Ref\< sc::Int2eCints \>**, **sc::Ref\< sc::Int2eV3 \>**, **sc::Ref\< sc::R12IntsAcc \>**, **sc::Ref\< sc::TwoBodyMOIntsTransform \>**, and **sc::Ref\< sc::OverlapOrthog \>**.

### void sc::RefBase::require\_nonnull () const

Requires that a nonnull reference is held. If not, the program will abort.

## Author

Generated automatically by Doxygen for MPQC from the source code.
