NCBI C++ ToolKit
Public Member Functions | Private Types | List of all members
CObjectHookGuard< T > Class Template Reference

Search Toolkit Book for CObjectHookGuard

Helper class: installs hooks in constructor, and uninstalls in destructor. More...

#include <serial/objhook.hpp>

+ Inheritance diagram for CObjectHookGuard< T >:
+ Collaboration diagram for CObjectHookGuard< T >:

Public Member Functions

 CObjectHookGuard (CReadObjectHook &hook, CObjectIStream *stream=0)
 Install object read hook. More...
 
 CObjectHookGuard (CWriteObjectHook &hook, CObjectOStream *stream=0)
 Install object write hook. More...
 
 CObjectHookGuard (CSkipObjectHook &hook, CObjectIStream *stream=0)
 Install object skip hook. More...
 
 CObjectHookGuard (CCopyObjectHook &hook, CObjectStreamCopier *stream=0)
 Install object copy hook. More...
 
 CObjectHookGuard (const string &id, CReadClassMemberHook &hook, CObjectIStream *stream=0)
 Install member read hook. More...
 
 CObjectHookGuard (const string &id, CWriteClassMemberHook &hook, CObjectOStream *stream=0)
 Install member write hook. More...
 
 CObjectHookGuard (const string &id, CSkipClassMemberHook &hook, CObjectIStream *stream=0)
 Install member skip hook. More...
 
 CObjectHookGuard (const string &id, CCopyClassMemberHook &hook, CObjectStreamCopier *stream=0)
 Install member copy hook. More...
 
 CObjectHookGuard (const string &id, CReadChoiceVariantHook &hook, CObjectIStream *stream=0)
 Install choice variant read hook. More...
 
 CObjectHookGuard (const string &id, CWriteChoiceVariantHook &hook, CObjectOStream *stream=0)
 Install choice variant write hook. More...
 
 CObjectHookGuard (const string &id, CSkipChoiceVariantHook &hook, CObjectIStream *stream=0)
 Install choice variant skip hook. More...
 
 CObjectHookGuard (const string &id, CCopyChoiceVariantHook &hook, CObjectStreamCopier *stream=0)
 Install choice variant copy hook. More...
 
 ~CObjectHookGuard (void)
 

Private Types

typedef CObjectHookGuardBase CParent
 

Additional Inherited Members

- Protected Member Functions inherited from CObjectHookGuardBase
 CObjectHookGuardBase (const CObjectTypeInfo &info, CReadObjectHook &hook, CObjectIStream *stream=0)
 
 CObjectHookGuardBase (const CObjectTypeInfo &info, CWriteObjectHook &hook, CObjectOStream *stream=0)
 
 CObjectHookGuardBase (const CObjectTypeInfo &info, CSkipObjectHook &hook, CObjectIStream *stream=0)
 
 CObjectHookGuardBase (const CObjectTypeInfo &info, CCopyObjectHook &hook, CObjectStreamCopier *stream=0)
 
 CObjectHookGuardBase (const CObjectTypeInfo &info, const string &id, CReadClassMemberHook &hook, CObjectIStream *stream=0)
 
 CObjectHookGuardBase (const CObjectTypeInfo &info, const string &id, CWriteClassMemberHook &hook, CObjectOStream *stream=0)
 
 CObjectHookGuardBase (const CObjectTypeInfo &info, const string &id, CSkipClassMemberHook &hook, CObjectIStream *stream=0)
 
 CObjectHookGuardBase (const CObjectTypeInfo &info, const string &id, CCopyClassMemberHook &hook, CObjectStreamCopier *stream=0)
 
 CObjectHookGuardBase (const CObjectTypeInfo &info, const string &id, CReadChoiceVariantHook &hook, CObjectIStream *stream=0)
 
 CObjectHookGuardBase (const CObjectTypeInfo &info, const string &id, CWriteChoiceVariantHook &hook, CObjectOStream *stream=0)
 
 CObjectHookGuardBase (const CObjectTypeInfo &info, const string &id, CSkipChoiceVariantHook &hook, CObjectIStream *stream=0)
 
 CObjectHookGuardBase (const CObjectTypeInfo &info, const string &id, CCopyChoiceVariantHook &hook, CObjectStreamCopier *stream=0)
 
 ~CObjectHookGuardBase (void)
 
void ResetHook (const CObjectTypeInfo &info)
 

Detailed Description

template<class T>
class CObjectHookGuard< T >

Helper class: installs hooks in constructor, and uninstalls in destructor.

Definition at line 396 of file objhook.hpp.

Member Typedef Documentation

template<class T>
typedef CObjectHookGuardBase CObjectHookGuard< T >::CParent
private

Definition at line 398 of file objhook.hpp.

Constructor & Destructor Documentation

template<class T>
CObjectHookGuard< T >::CObjectHookGuard ( CReadObjectHook hook,
CObjectIStream stream = 0 
)
inline

Install object read hook.

Parameters
hookHook object
streamData stream: if 0, the global hook is installed, otherwise - local one

Definition at line 407 of file objhook.hpp.

template<class T>
CObjectHookGuard< T >::CObjectHookGuard ( CWriteObjectHook hook,
CObjectOStream stream = 0 
)
inline

Install object write hook.

Parameters
hookHook object
streamData stream: if 0, the global hook is installed, otherwise - local one

Definition at line 419 of file objhook.hpp.

template<class T>
CObjectHookGuard< T >::CObjectHookGuard ( CSkipObjectHook hook,
CObjectIStream stream = 0 
)
inline

Install object skip hook.

Parameters
hookHook object
streamData stream: if 0, the global hook is installed, otherwise - local one

Definition at line 431 of file objhook.hpp.

template<class T>
CObjectHookGuard< T >::CObjectHookGuard ( CCopyObjectHook hook,
CObjectStreamCopier stream = 0 
)
inline

Install object copy hook.

Parameters
hookHook object
streamData stream: if 0, the global hook is installed, otherwise - local one

Definition at line 443 of file objhook.hpp.

template<class T>
CObjectHookGuard< T >::CObjectHookGuard ( const string id,
CReadClassMemberHook hook,
CObjectIStream stream = 0 
)
inline

Install member read hook.

Parameters
idMember id
hookHook object
streamData stream: if 0, the global hook is installed, otherwise - local one

Definition at line 458 of file objhook.hpp.

template<class T>
CObjectHookGuard< T >::CObjectHookGuard ( const string id,
CWriteClassMemberHook hook,
CObjectOStream stream = 0 
)
inline

Install member write hook.

Parameters
idMember id
hookHook object
streamData stream: if 0, the global hook is installed, otherwise - local one

Definition at line 474 of file objhook.hpp.

template<class T>
CObjectHookGuard< T >::CObjectHookGuard ( const string id,
CSkipClassMemberHook hook,
CObjectIStream stream = 0 
)
inline

Install member skip hook.

Parameters
idMember id
hookHook object
streamData stream: if 0, the global hook is installed, otherwise - local one

Definition at line 490 of file objhook.hpp.

template<class T>
CObjectHookGuard< T >::CObjectHookGuard ( const string id,
CCopyClassMemberHook hook,
CObjectStreamCopier stream = 0 
)
inline

Install member copy hook.

Parameters
idMember id
hookHook object
streamData stream: if 0, the global hook is installed, otherwise - local one

Definition at line 506 of file objhook.hpp.

template<class T>
CObjectHookGuard< T >::CObjectHookGuard ( const string id,
CReadChoiceVariantHook hook,
CObjectIStream stream = 0 
)
inline

Install choice variant read hook.

Parameters
idVariant id
hookHook object
streamData stream: if 0, the global hook is installed, otherwise - local one

Definition at line 522 of file objhook.hpp.

template<class T>
CObjectHookGuard< T >::CObjectHookGuard ( const string id,
CWriteChoiceVariantHook hook,
CObjectOStream stream = 0 
)
inline

Install choice variant write hook.

Parameters
idVariant id
hookHook object
streamData stream: if 0, the global hook is installed, otherwise - local one

Definition at line 538 of file objhook.hpp.

template<class T>
CObjectHookGuard< T >::CObjectHookGuard ( const string id,
CSkipChoiceVariantHook hook,
CObjectIStream stream = 0 
)
inline

Install choice variant skip hook.

Parameters
idVariant id
hookHook object
streamData stream: if 0, the global hook is installed, otherwise - local one

Definition at line 554 of file objhook.hpp.

template<class T>
CObjectHookGuard< T >::CObjectHookGuard ( const string id,
CCopyChoiceVariantHook hook,
CObjectStreamCopier stream = 0 
)
inline

Install choice variant copy hook.

Parameters
idVariant id
hookHook object
streamData stream: if 0, the global hook is installed, otherwise - local one

Definition at line 570 of file objhook.hpp.

template<class T>
CObjectHookGuard< T >::~CObjectHookGuard ( void  )
inline

Definition at line 577 of file objhook.hpp.

References CObjectHookGuardBase::ResetHook().


The documentation for this class was generated from the following file:
Modified on Sun Jun 25 17:44:08 2017 by modify_doxy.py rev. 533848