Fermi Physics Class Libraries Module: HolderPtr


HolderPtr Class Sub-package

This mini-package provides a simple template class, HolderPtr, that can serve as a pointer to an object, with the property that when the HolderPtr is copied, it creates its own copy of the object pointed to as well.

This copy is made using the object's virtual clone() method if such a method exists, or using the copy constructor if not. That mkae it possible for a HolderPtr that is declared to point to some base class B but actually is used to point to a derived class D to make a clone of the full D object rather than its B slice.

Complete documentatoin may be found at a Guru-of-the-week page.

This package may be obtained from the following sources:

Walter Brown, Module Coordinator
Fermilab Physics Class Library Task Force

Comments, questions about getting started, feature needs, and bug/annoyance reports may be sent to zoom-support@fnal.gov or zoom@fnal.gov.

This class was adapted from an idea presented by H.P. Sutter on the Guru of the Week Solution number 62. It was presented by Marc Paterno. Walter Brown edited the result for conformance to Zoom standards.

ZMtools main page - ZOOM Home Page - Fermilab at Work - Fermilab Home

Walter Brown
Last modified: May 19, 2000.