NCBI C++ ToolKit
objhook.hpp
Go to the documentation of this file.

Go to the SVN repository for this file.

1 #ifndef OBJHOOK__HPP
2 #define OBJHOOK__HPP
3 
4 /* $Id: objhook.hpp 76758 2017-03-02 16:00:11Z gouriano $
5 * ===========================================================================
6 *
7 * PUBLIC DOMAIN NOTICE
8 * National Center for Biotechnology Information
9 *
10 * This software/database is a "United States Government Work" under the
11 * terms of the United States Copyright Act. It was written as part of
12 * the author's official duties as a United States Government employee and
13 * thus cannot be copyrighted. This software/database is freely available
14 * to the public for use. The National Library of Medicine and the U.S.
15 * Government have not placed any restriction on its use or reproduction.
16 *
17 * Although all reasonable efforts have been taken to ensure the accuracy
18 * and reliability of the software and data, the NLM and the U.S.
19 * Government do not and cannot warrant the performance or results that
20 * may be obtained by using this software or data. The NLM and the U.S.
21 * Government disclaim all warranties, express or implied, including
22 * warranties of performance, merchantability or fitness for any particular
23 * purpose.
24 *
25 * Please cite the author in any work or product based on this material.
26 *
27 * ===========================================================================
28 *
29 * Author: Eugene Vasilchenko
30 *
31 * File Description:
32 * Read and write hooks
33 */
34 
35 #include <util/util_exception.hpp>
36 #include <serial/serialdef.hpp>
38 #include <serial/impl/objstack.hpp>
39 #include <serial/objectiter.hpp>
40 
41 
42 /** @addtogroup ObjStreamSupport
43  *
44  * @{
45  */
46 
47 
49 
50 class CObjectIStream;
51 class CObjectOStream;
53 class CObjectInfo;
54 class CConstObjectInfo;
55 class CObjectTypeInfo;
56 
57 /// Read hook for a standalone object
59 {
60 public:
61  virtual ~CReadObjectHook(void);
62 
63  /// This method will be called at approriate time
64  /// when the object of requested type is to be read
65  virtual void ReadObject(CObjectIStream& in,
66  const CObjectInfo& object) = 0;
67  // Default actions
68  /// Default read
69  void DefaultRead(CObjectIStream& in,
70  const CObjectInfo& object);
71  /// Default skip
72  void DefaultSkip(CObjectIStream& in,
73  const CObjectTypeInfo& object);
74 };
75 
76 /// Read hook for data member of a containing object (eg, SEQUENCE)
78 {
79 public:
80  virtual ~CReadClassMemberHook(void);
81 
82  /// This method will be called at approriate time
83  /// when the object of requested type is to be read
84  virtual void ReadClassMember(CObjectIStream& in,
85  const CObjectInfoMI& member) = 0;
86  virtual void ReadMissingClassMember(CObjectIStream& in,
87  const CObjectInfoMI& member);
88  void DefaultRead(CObjectIStream& in,
89  const CObjectInfoMI& object);
90  void DefaultSkip(CObjectIStream& in,
91  const CObjectTypeInfoMI& object);
92  void ResetMember(const CObjectInfoMI& object,
95 };
96 
97 /// Read hook for data member of a containing object (eg, SEQUENCE)
99  : public CReadClassMemberHook
100 {
101 public:
102  virtual ~CPreReadClassMemberHook(void);
103 
104  /// This method will be called at approriate time
105  /// when the object of requested type is to be read
106  virtual void ReadClassMember(CObjectIStream& in,
107  const CObjectInfoMI& member);
108 
109  /// Return true to invoke default reading method afterwards.
110  /// Return false if no firther reading needs to be done.
111  virtual void PreReadClassMember(CObjectIStream& in,
112  const CObjectInfoMI& member) = 0;
113 };
114 
115 /// Read hook for a choice variant (CHOICE)
117 {
118 public:
119  virtual ~CReadChoiceVariantHook(void);
120 
121  /// This method will be called at approriate time
122  /// when the object of requested type is to be read
123  virtual void ReadChoiceVariant(CObjectIStream& in,
124  const CObjectInfoCV& variant) = 0;
125  void DefaultRead(CObjectIStream& in,
126  const CObjectInfoCV& object);
127  void DefaultSkip(CObjectIStream& in,
128  const CObjectTypeInfoCV& object);
129 };
130 
131 /// Read hook for a choice variant (CHOICE)
133  : public CReadChoiceVariantHook
134 {
135 public:
136  virtual ~CPreReadChoiceVariantHook(void);
137 
138  /// This method will be called at approriate time
139  /// when the object of requested type is to be read
140  virtual void ReadChoiceVariant(CObjectIStream& in,
141  const CObjectInfoCV& variant);
142 
143  /// Return true to invoke default reading method afterwards.
144  /// Return false if no firther reading needs to be done.
145  virtual void PreReadChoiceVariant(CObjectIStream& in,
146  const CObjectInfoCV& object) = 0;
147 };
148 
149 /// Read hook for a container element (SEQUENCE OF)
151 {
152 public:
153  virtual ~CReadContainerElementHook(void);
154 
155  virtual void ReadContainerElement(CObjectIStream& in,
156  const CObjectInfo& container) = 0;
157 };
158 
159 /// Write hook for a standalone object
161 {
162 public:
163  virtual ~CWriteObjectHook(void);
164 
165  /// This method will be called at approriate time
166  /// when the object of requested type is to be written
167  virtual void WriteObject(CObjectOStream& out,
168  const CConstObjectInfo& object) = 0;
169  void DefaultWrite(CObjectOStream& out,
170  const CConstObjectInfo& object);
171 };
172 
173 /// Write hook for data member of a containing object (eg, SEQUENCE)
175 {
176 public:
177  virtual ~CWriteClassMemberHook(void);
178 
179  virtual void WriteClassMember(CObjectOStream& out,
180  const CConstObjectInfoMI& member) = 0;
181  void DefaultWrite(CObjectOStream& out,
182  const CConstObjectInfoMI& member);
183  void CustomWrite(CObjectOStream& out,
184  const CConstObjectInfoMI& member,
185  const CConstObjectInfo& custom_object);
186 };
187 
188 /// Write hook for a choice variant (CHOICE)
190 {
191 public:
192  virtual ~CWriteChoiceVariantHook(void);
193 
194  virtual void WriteChoiceVariant(CObjectOStream& out,
195  const CConstObjectInfoCV& variant) = 0;
196  void DefaultWrite(CObjectOStream& out,
197  const CConstObjectInfoCV& variant);
198  void CustomWrite(CObjectOStream& out,
199  const CConstObjectInfoCV& variant,
200  const CConstObjectInfo& custom_object);
201 };
202 
203 /// Skip hook for a standalone object
205 {
206 public:
207  virtual ~CSkipObjectHook(void);
208 
209  virtual void SkipObject(CObjectIStream& stream,
210  const CObjectTypeInfo& type) = 0;
211 
212  // Default actions
213  /// Default read
214  void DefaultRead(CObjectIStream& in,
215  const CObjectInfo& object);
216  /// Default skip
217  void DefaultSkip(CObjectIStream& in,
218  const CObjectTypeInfo& type);
219 };
220 
221 /// Skip hook for data member of a containing object (eg, SEQUENCE)
223 {
224 public:
225  virtual ~CSkipClassMemberHook(void);
226 
227  virtual void SkipClassMember(CObjectIStream& stream,
228  const CObjectTypeInfoMI& member) = 0;
229  virtual void SkipMissingClassMember(CObjectIStream& stream,
230  const CObjectTypeInfoMI& member);
231  void DefaultRead(CObjectIStream& in,
232  const CObjectInfo& object);
233  void DefaultSkip(CObjectIStream& stream,
234  const CObjectTypeInfoMI& member);
235 };
236 
237 /// Skip hook for a choice variant (CHOICE)
239 {
240 public:
241  virtual ~CSkipChoiceVariantHook(void);
242 
243  virtual void SkipChoiceVariant(CObjectIStream& stream,
244  const CObjectTypeInfoCV& variant) = 0;
245  void DefaultRead(CObjectIStream& in,
246  const CObjectInfo& object);
247  void DefaultSkip(CObjectIStream& stream,
248  const CObjectTypeInfoCV& variant);
249 };
250 
251 
252 /// Copy hook for a standalone object
254 {
255 public:
256  virtual ~CCopyObjectHook(void);
257 
258  virtual void CopyObject(CObjectStreamCopier& copier,
259  const CObjectTypeInfo& type) = 0;
260  void DefaultCopy(CObjectStreamCopier& copier,
261  const CObjectTypeInfo& type);
262 };
263 
264 /// Copy hook for data member of a containing object (eg, SEQUENCE)
266 {
267 public:
268  virtual ~CCopyClassMemberHook(void);
269 
270  virtual void CopyClassMember(CObjectStreamCopier& copier,
271  const CObjectTypeInfoMI& member) = 0;
272  virtual void CopyMissingClassMember(CObjectStreamCopier& copier,
273  const CObjectTypeInfoMI& member);
274  void DefaultCopy(CObjectStreamCopier& copier,
275  const CObjectTypeInfoMI& member);
276 };
277 
278 /// Copy hook for a choice variant (CHOICE)
280 {
281 public:
282  virtual ~CCopyChoiceVariantHook(void);
283 
284  virtual void CopyChoiceVariant(CObjectStreamCopier& copier,
285  const CObjectTypeInfoCV& variant) = 0;
286  void DefaultCopy(CObjectStreamCopier& copier,
287  const CObjectTypeInfoCV& variant);
288 };
289 
290 
292  eDefault_Normal, // read or write data
293  eDefault_Skip // skip data
294 };
295 
296 
298 {
299 protected:
300  // object read hook
302  CReadObjectHook& hook,
303  CObjectIStream* stream = 0);
304  // object write hook
306  CWriteObjectHook& hook,
307  CObjectOStream* stream = 0);
308  // object skip hook
310  CSkipObjectHook& hook,
311  CObjectIStream* stream = 0);
312  // object copy hook
314  CCopyObjectHook& hook,
315  CObjectStreamCopier* stream = 0);
316 
317  // member read hook
319  const string& id,
320  CReadClassMemberHook& hook,
321  CObjectIStream* stream = 0);
322  // member write hook
324  const string& id,
325  CWriteClassMemberHook& hook,
326  CObjectOStream* stream = 0);
327  // member skip hook
329  const string& id,
330  CSkipClassMemberHook& hook,
331  CObjectIStream* stream = 0);
332  // member copy hook
334  const string& id,
335  CCopyClassMemberHook& hook,
336  CObjectStreamCopier* stream = 0);
337 
338  // choice variant read hook
340  const string& id,
342  CObjectIStream* stream = 0);
343  // choice variant write hook
345  const string& id,
347  CObjectOStream* stream = 0);
348  // choice variant skip hook
350  const string& id,
352  CObjectIStream* stream = 0);
353  // choice variant copy hook
355  const string& id,
357  CObjectStreamCopier* stream = 0);
358 
359  ~CObjectHookGuardBase(void);
360 
361  void ResetHook(const CObjectTypeInfo& info);
362 
363 private:
365  const CObjectHookGuardBase& operator=(const CObjectHookGuardBase&);
366 
367  enum EHookMode {
372  eHook_Copy
373  };
374  enum EHookType {
375  eHook_Null, // object hook
376  eHook_Object, // object hook
377  eHook_Member, // class member hook
378  eHook_Variant, // choice variant hook
379  eHook_Element // container element hook
380  };
381 
382  union {
386  } m_Stream;
390  string m_Id; // member or variant id
391 };
392 
393 
394 /// Helper class: installs hooks in constructor, and uninstalls in destructor
395 template <class T>
397 {
399 public:
400  /// Install object read hook
401  ///
402  /// @param hook
403  /// Hook object
404  /// @param stream
405  /// Data stream: if 0, the global hook is installed,
406  /// otherwise - local one
408  CObjectIStream* stream = 0)
409  : CParent(CType<T>(), hook, stream)
410  {
411  }
412  /// Install object write hook
413  ///
414  /// @param hook
415  /// Hook object
416  /// @param stream
417  /// Data stream: if 0, the global hook is installed,
418  /// otherwise - local one
420  CObjectOStream* stream = 0)
421  : CParent(CType<T>(), hook, stream)
422  {
423  }
424  /// Install object skip hook
425  ///
426  /// @param hook
427  /// Hook object
428  /// @param stream
429  /// Data stream: if 0, the global hook is installed,
430  /// otherwise - local one
432  CObjectIStream* stream = 0)
433  : CParent(CType<T>(), hook, stream)
434  {
435  }
436  /// Install object copy hook
437  ///
438  /// @param hook
439  /// Hook object
440  /// @param stream
441  /// Data stream: if 0, the global hook is installed,
442  /// otherwise - local one
444  CObjectStreamCopier* stream = 0)
445  : CParent(CType<T>(), hook, stream)
446  {
447  }
448 
449  /// Install member read hook
450  ///
451  /// @param id
452  /// Member id
453  /// @param hook
454  /// Hook object
455  /// @param stream
456  /// Data stream: if 0, the global hook is installed,
457  /// otherwise - local one
458  CObjectHookGuard(const string& id,
459  CReadClassMemberHook& hook,
460  CObjectIStream* stream = 0)
461  : CParent(CType<T>(), id, hook, stream)
462  {
463  }
464 
465  /// Install member write hook
466  ///
467  /// @param id
468  /// Member id
469  /// @param hook
470  /// Hook object
471  /// @param stream
472  /// Data stream: if 0, the global hook is installed,
473  /// otherwise - local one
474  CObjectHookGuard(const string& id,
475  CWriteClassMemberHook& hook,
476  CObjectOStream* stream = 0)
477  : CParent(CType<T>(), id, hook, stream)
478  {
479  }
480 
481  /// Install member skip hook
482  ///
483  /// @param id
484  /// Member id
485  /// @param hook
486  /// Hook object
487  /// @param stream
488  /// Data stream: if 0, the global hook is installed,
489  /// otherwise - local one
490  CObjectHookGuard(const string& id,
491  CSkipClassMemberHook& hook,
492  CObjectIStream* stream = 0)
493  : CParent(CType<T>(), id, hook, stream)
494  {
495  }
496 
497  /// Install member copy hook
498  ///
499  /// @param id
500  /// Member id
501  /// @param hook
502  /// Hook object
503  /// @param stream
504  /// Data stream: if 0, the global hook is installed,
505  /// otherwise - local one
506  CObjectHookGuard(const string& id,
507  CCopyClassMemberHook& hook,
508  CObjectStreamCopier* stream = 0)
509  : CParent(CType<T>(), id, hook, stream)
510  {
511  }
512 
513  /// Install choice variant read hook
514  ///
515  /// @param id
516  /// Variant id
517  /// @param hook
518  /// Hook object
519  /// @param stream
520  /// Data stream: if 0, the global hook is installed,
521  /// otherwise - local one
522  CObjectHookGuard(const string& id,
524  CObjectIStream* stream = 0)
525  : CParent(CType<T>(), id, hook, stream)
526  {
527  }
528 
529  /// Install choice variant write hook
530  ///
531  /// @param id
532  /// Variant id
533  /// @param hook
534  /// Hook object
535  /// @param stream
536  /// Data stream: if 0, the global hook is installed,
537  /// otherwise - local one
538  CObjectHookGuard(const string& id,
540  CObjectOStream* stream = 0)
541  : CParent(CType<T>(), id, hook, stream)
542  {
543  }
544 
545  /// Install choice variant skip hook
546  ///
547  /// @param id
548  /// Variant id
549  /// @param hook
550  /// Hook object
551  /// @param stream
552  /// Data stream: if 0, the global hook is installed,
553  /// otherwise - local one
554  CObjectHookGuard(const string& id,
556  CObjectIStream* stream = 0)
557  : CParent(CType<T>(), id, hook, stream)
558  {
559  }
560 
561  /// Install choice variant copy hook
562  ///
563  /// @param id
564  /// Variant id
565  /// @param hook
566  /// Hook object
567  /// @param stream
568  /// Data stream: if 0, the global hook is installed,
569  /// otherwise - local one
570  CObjectHookGuard(const string& id,
572  CObjectStreamCopier* stream = 0)
573  : CParent(CType<T>(), id, hook, stream)
574  {
575  }
576 
578  {
580  }
581 };
582 
583 
584 /// Helper hook for Serial_FilterObjects function template;
585 /// User hook class should be derived from this base class
586 template<typename TObject>
588 {
589 public:
591  {
592  if (type.GetTypeInfo()->IsCObject()) {
593  TObjectPtr objectPtr = type.GetTypeInfo()->Create(/*in.GetMemoryPool()*/);
594  CRef<CObject> ref;
595  ref.Reset(static_cast<CObject*>(objectPtr));
596  type.GetTypeInfo()->DefaultReadData(in, objectPtr);
597  Process(*static_cast<TObject*>(objectPtr));
598  } else {
599  TObject obj;
600  type.GetTypeInfo()->DefaultReadData(in, &obj);
601  Process(obj);
602  }
603  }
604  /// This method will be called when the object of the
605  /// requested class is read
606  virtual void Process(const TObject& obj) = 0;
607 };
608 
609 template<typename TObject>
611 {
612 public:
615  : m_processor(processor)
616  {
617  }
619  {
620  DefaultRead(in,object);
621  TObject* obj = (TObject*)(object.GetObjectPtr());
622  m_processor->Process(*obj);
623  }
624 private:
626 };
627 
630 
631 /// Scan input stream, finding objects of requested type (TObject) only
632 template<typename TRoot, typename TObject>
634  bool readall=true)
635 {
636  CObjectTypeInfo root = CType<TRoot>();
637  CObjectTypeInfo request = CType<TObject>();
638  request.SetLocalSkipHook(in, hook);
639  request.SetLocalReadHook(in, new CSerial_FilterReadObjectsHook<TObject>(hook));
640  while (Serial_FilterSkip(in,root) && readall)
641  ;
642 }
643 
644 /// Scan input stream, finding objects that are not derived from CSerialObject
645 template<typename TRoot, typename TObject>
647  bool readall=true)
648 {
649  CObjectTypeInfo root = CType<TRoot>();
651  request.SetLocalSkipHook(in, hook);
652  while (Serial_FilterSkip(in,root) && readall)
653  ;
654 }
655 
656 
657 
658 
659 /* @} */
660 
661 
663 
664 #endif /* OBJHOOK__HPP */
Read hook for a choice variant (CHOICE)
Definition: objhook.hpp:116
void ResetHook(const CObjectTypeInfo &info)
Definition: objhook.cpp:488
CObjectIStream –.
Definition: objistr.hpp:92
Helper class: installs hooks in constructor, and uninstalls in destructor.
Definition: objhook.hpp:396
CObjectHookGuard(CReadObjectHook &hook, CObjectIStream *stream=0)
Install object read hook.
Definition: objhook.hpp:407
CObjectTypeInfoMI –.
Definition: objectiter.hpp:240
void DefaultReadData(CObjectIStream &in, TObjectPtr object) const
Helper hook for Serial_FilterObjects function template; User hook class should be derived from this b...
Definition: objhook.hpp:587
#define T(s)
Definition: common.h:225
EHookType m_HookType
Definition: objhook.hpp:389
CObjectInfoMI –.
Definition: objectiter.hpp:426
Copy hook for data member of a containing object (eg, SEQUENCE)
Definition: objhook.hpp:265
CObjectHookGuard(const string &id, CWriteChoiceVariantHook &hook, CObjectOStream *stream=0)
Install choice variant write hook.
Definition: objhook.hpp:538
std::ofstream out("events_result.xml")
main entry point for tests
~CObjectHookGuard(void)
Definition: objhook.hpp:577
CObjectOStream –.
Definition: objostr.hpp:82
CObjectTypeInfo –.
Definition: objectinfo.hpp:93
CObjectInfo –.
Definition: objectinfo.hpp:596
Write hook for a standalone object.
Definition: objhook.hpp:160
CObjectStreamCopier –.
Definition: objcopy.hpp:70
Read hook for a choice variant (CHOICE)
Definition: objhook.hpp:132
EHookMode m_HookMode
Definition: objhook.hpp:388
CObjectHookGuard(CCopyObjectHook &hook, CObjectStreamCopier *stream=0)
Install object copy hook.
Definition: objhook.hpp:443
CRef< CObject > m_Hook
Definition: objhook.hpp:387
CObjectHookGuard(const string &id, CCopyChoiceVariantHook &hook, CObjectStreamCopier *stream=0)
Install choice variant copy hook.
Definition: objhook.hpp:570
static void WriteClassMember(CObjectOStream &out, const CObjectInfoMI &member)
Definition: read_hooks.cpp:46
Skip hook for data member of a containing object (eg, SEQUENCE)
Definition: objhook.hpp:222
void Serial_FilterObjects(CObjectIStream &in, CSerial_FilterObjectsHook< TObject > *hook, bool readall=true)
Scan input stream, finding objects of requested type (TObject) only.
Definition: objhook.hpp:633
Read hook for data member of a containing object (eg, SEQUENCE)
Definition: objhook.hpp:77
CObjectIStream * m_IStream
Definition: objhook.hpp:383
CObjectHookGuard(const string &id, CSkipChoiceVariantHook &hook, CObjectIStream *stream=0)
Install choice variant skip hook.
Definition: objhook.hpp:554
CObjectHookGuard(const string &id, CCopyClassMemberHook &hook, CObjectStreamCopier *stream=0)
Install member copy hook.
Definition: objhook.hpp:506
TObjectPtr Create(CObjectMemoryPool *memoryPool=0) const
Create object of this type on heap (can be deleted by operator delete)
#define END_NCBI_SCOPE
End previously defined NCBI scope.
Definition: ncbistl.hpp:101
bool IsCObject(void) const
Check is this TypeInfo object is kind of CClassTypeInfoBase.
CObjectHookGuard(CWriteObjectHook &hook, CObjectOStream *stream=0)
Install object write hook.
Definition: objhook.hpp:419
virtual void ReadChoiceVariant(CObjectIStream &in, const CObjectInfoCV &variant)=0
This method will be called at approriate time when the object of requested type is to be read...
Write hook for a choice variant (CHOICE)
Definition: objhook.hpp:189
CObjectHookGuard(const string &id, CReadClassMemberHook &hook, CObjectIStream *stream=0)
Install member read hook.
Definition: objhook.hpp:458
Definition: type.c:8
default - erase optional member only
Definition: objectiter.hpp:449
EDefaultHookAction
Definition: objhook.hpp:291
CObjectStreamCopier * m_Copier
Definition: objhook.hpp:385
Read hook for a container element (SEQUENCE OF)
Definition: objhook.hpp:150
CObjectOStream * m_OStream
Definition: objhook.hpp:384
Read hook for a standalone object.
Definition: objhook.hpp:58
virtual void Process(const TObject &obj)=0
This method will be called when the object of the requested class is read.
CConstObjectInfoCV –.
Definition: objectiter.hpp:551
#define NCBI_XSERIAL_EXPORT
Definition: ncbi_export.h:1410
Copy hook for a choice variant (CHOICE)
Definition: objhook.hpp:279
CObjectHookGuard(CSkipObjectHook &hook, CObjectIStream *stream=0)
Install object skip hook.
Definition: objhook.hpp:431
CNcbiOstream & WriteObject(CNcbiOstream &str, TConstObjectPtr ptr, TTypeInfo info)
bool Serial_FilterSkip(CObjectIStream &in, const CObjectTypeInfo &ctype)
Definition: serial.cpp:76
CObjectHookGuard(const string &id, CSkipClassMemberHook &hook, CObjectIStream *stream=0)
Install member skip hook.
Definition: objhook.hpp:490
Skip hook for a choice variant (CHOICE)
Definition: objhook.hpp:238
CObjectHookGuard(const string &id, CReadChoiceVariantHook &hook, CObjectIStream *stream=0)
Install choice variant read hook.
Definition: objhook.hpp:522
CObject –.
Definition: ncbiobj.hpp:180
CObjectHookGuard(const string &id, CWriteClassMemberHook &hook, CObjectOStream *stream=0)
Install member write hook.
Definition: objhook.hpp:474
void ReadObject(CObjectIStream &in, const CObjectInfo &object)
This method will be called at approriate time when the object of requested type is to be read...
Definition: objhook.hpp:618
CObjectTypeInfoCV –.
Definition: objectiter.hpp:471
virtual void ReadClassMember(CObjectIStream &in, const CObjectInfoMI &member)=0
This method will be called at approriate time when the object of requested type is to be read...
CConstObjectInfoMI –.
Definition: objectiter.hpp:391
Write hook for data member of a containing object (eg, SEQUENCE)
Definition: objhook.hpp:174
CConstObjectInfo –.
Definition: objectinfo.hpp:420
CNcbiIstream & ReadObject(CNcbiIstream &str, TObjectPtr ptr, TTypeInfo info)
void Serial_FilterStdObjects(CObjectIStream &in, CSerial_FilterObjectsHook< TObject > *hook, bool readall=true)
Scan input stream, finding objects that are not derived from CSerialObject.
Definition: objhook.hpp:646
CObjectHookGuardBase CParent
Definition: objhook.hpp:398
std::istream & in(std::istream &in_, double &x_)
Read hook for data member of a containing object (eg, SEQUENCE)
Definition: objhook.hpp:98
CObjectInfoCV –.
Definition: objectiter.hpp:583
Copy hook for a standalone object.
Definition: objhook.hpp:253
void * TObjectPtr
Definition: serialdef.hpp:55
TTypeInfo GetTypeInfo(void) const
CSerial_FilterObjectsHook< TObject > * m_processor
Definition: objhook.hpp:625
#define BEGIN_NCBI_SCOPE
Define ncbi namespace.
Definition: ncbistl.hpp:98
void SkipObject(CObjectIStream &in, const CObjectTypeInfo &type)
Definition: objhook.hpp:590
Skip hook for a standalone object.
Definition: objhook.hpp:204
EEraseFlag
Erase types.
Definition: objectiter.hpp:448
void DefaultRead(CObjectIStream &in, const CObjectInfo &object)
Default read.
Definition: objhook.cpp:171
void Reset(void)
Reset reference object.
Definition: ncbiobj.hpp:756
Modified on Sun Jun 25 17:49:25 2017 by modify_doxy.py rev. 533848