NCBI C++ ToolKit
ArticleId_.cpp
Go to the documentation of this file.

Go to the SVN repository for this file.

1 /* $Id$
2  * ===========================================================================
3  *
4  * PUBLIC DOMAIN NOTICE
5  * National Center for Biotechnology Information
6  *
7  * This software/database is a "United States Government Work" under the
8  * terms of the United States Copyright Act. It was written as part of
9  * the author's official duties as a United States Government employee and
10  * thus cannot be copyrighted. This software/database is freely available
11  * to the public for use. The National Library of Medicine and the U.S.
12  * Government have not placed any restriction on its use or reproduction.
13  *
14  * Although all reasonable efforts have been taken to ensure the accuracy
15  * and reliability of the software and data, the NLM and the U.S.
16  * Government do not and cannot warrant the performance or results that
17  * may be obtained by using this software or data. The NLM and the U.S.
18  * Government disclaim all warranties, express or implied, including
19  * warranties of performance, merchantability or fitness for any particular
20  * purpose.
21  *
22  * Please cite the author in any work or product based on this material.
23  *
24  * ===========================================================================
25  *
26  * File Description:
27  * This code was generated by application DATATOOL
28  * using the following specifications:
29  * 'efetch.xsd'.
30  *
31  * ATTENTION:
32  * Don't edit or commit this file into CVS as this file will
33  * be overridden (by DATATOOL) without warning!
34  * ===========================================================================
35  */
36 
37 // standard includes
38 #include <ncbi_pch.hpp>
39 #include <serial/serialimpl.hpp>
40 
41 // generated includes
43 BEGIN_eutils_SCOPE // namespace eutils::
44 
45 
46 // generated classes
47 
49 {
50  SET_ENUM_INTERNAL_NAME("ArticleId.Attlist", "IdType");
51  SET_ENUM_MODULE("efetch");
52  ADD_ENUM_VALUE("doi", eAttlist_IdType_doi);
53  ADD_ENUM_VALUE("pii", eAttlist_IdType_pii);
54  ADD_ENUM_VALUE("pmcpid", eAttlist_IdType_pmcpid);
55  ADD_ENUM_VALUE("pmpid", eAttlist_IdType_pmpid);
56  ADD_ENUM_VALUE("pmc", eAttlist_IdType_pmc);
57  ADD_ENUM_VALUE("mid", eAttlist_IdType_mid);
58  ADD_ENUM_VALUE("sici", eAttlist_IdType_sici);
59  ADD_ENUM_VALUE("pubmed", eAttlist_IdType_pubmed);
60  ADD_ENUM_VALUE("medline", eAttlist_IdType_medline);
61  ADD_ENUM_VALUE("pmcid", eAttlist_IdType_pmcid);
62  ADD_ENUM_VALUE("pmcbook", eAttlist_IdType_pmcbook);
63  ADD_ENUM_VALUE("bookaccession", eAttlist_IdType_bookaccession);
64 }
66 
68 {
69  ResetIdType();
70 }
71 
73 {
74  SET_INTERNAL_NAME("ArticleId", "Attlist");
75  SET_CLASS_MODULE("efetch");
76  ADD_NAMED_ENUM_MEMBER("IdType", m_IdType, EAttlist_IdType)->SetDefault(new TIdType(eAttlist_IdType_pubmed))->SetSetFlag(MEMBER_PTR(m_set_State[0]))->SetOptional()->SetNsQualified(false);
77  info->SetRandomOrder(true);
78  info->CodeVersion(22400);
79  info->DataSpec(ncbi::EDataSpec::eXSD);
80 }
82 
83 // constructor
85  : m_IdType(eAttlist_IdType_pubmed)
86 {
87  memset(m_set_State,0,sizeof(m_set_State));
88 }
89 
90 // destructor
92 {
93 }
94 
95 
97 {
98  if ( !m_Attlist ) {
99  m_Attlist.Reset(new TAttlist());
100  return;
101  }
102  (*m_Attlist).Reset();
103 }
104 
106 {
107  m_Attlist.Reset(&value);
108 }
109 
111 {
112  m_ArticleId.erase();
113  m_set_State[0] &= ~0xc;
114 }
115 
116 void CArticleId_Base::Reset(void)
117 {
118  ResetAttlist();
119  ResetArticleId();
120 }
121 
123 {
124  SET_CLASS_MODULE("efetch");
125  SET_NAMESPACE("http://www.ncbi.nlm.nih.gov")->SetNsQualified(true);
126  ADD_NAMED_REF_MEMBER("Attlist", m_Attlist, C_Attlist)->SetAttlist();
127  ADD_NAMED_STD_MEMBER("ArticleId", m_ArticleId)->SetSetFlag(MEMBER_PTR(m_set_State[0]))->SetNotag();
128  info->RandomOrder();
129  info->CodeVersion(22400);
130  info->DataSpec(ncbi::EDataSpec::eXSD);
131 }
133 
134 // constructor
136 {
137  memset(m_set_State,0,sizeof(m_set_State));
138  if ( !IsAllocatedInPool() ) {
139  ResetAttlist();
140  }
141 }
142 
143 // destructor
145 {
146 }
147 
148 
149 
150 END_eutils_SCOPE // namespace eutils::
151 
#define BEGIN_eutils_SCOPE
Definition: Abstract_.hpp:51
#define END_eutils_SCOPE
Definition: Abstract_.hpp:52
END_ENUM_INFO
Definition: aln_errors.cpp:58
CArticleId –.
Definition: ArticleId.hpp:66
#define MEMBER_PTR(MemberName)
Definition: serialimpl.hpp:284
#define SET_ENUM_INTERNAL_NAME(OwnerName, MemberName)
Definition: serialimpl.hpp:559
#define ADD_NAMED_REF_MEMBER(MemberAlias, MemberName, ClassName)
Definition: serialimpl.hpp:357
#define SET_ENUM_MODULE(ModuleName)
Definition: serialimpl.hpp:553
#define END_CLASS_INFO
Definition: serialimpl.hpp:456
#define ADD_NAMED_STD_MEMBER(MemberAlias, MemberName)
Definition: serialimpl.hpp:345
#define SET_CLASS_MODULE(ModuleName)
Definition: serialimpl.hpp:444
#define SET_NAMESPACE(name)
Definition: serialimpl.hpp:450
#define ADD_NAMED_ENUM_MEMBER(MemberAlias, MemberName, EnumName)
Definition: serialimpl.hpp:351
#define ADD_ENUM_VALUE(EnumValueName, EnumValueValue)
Definition: serialimpl.hpp:562
#define SET_INTERNAL_NAME(OwnerName, MemberName)
Definition: serialimpl.hpp:447
bool IsAllocatedInPool(void) const THROWS_NONE
Check if object is allocated in memory pool (not system heap)
Definition: ncbiobj.hpp:461
virtual void Reset(void)
Reset the whole object.
Definition: ArticleId_.cpp:51
virtual ~CArticleId_Base(void)
Definition: ArticleId_.cpp:235
void ResetIdType(void)
Reset IdType data member.
Definition: ArticleId_.hpp:310
void ResetAttlist(void)
Reset Attlist data member.
Definition: ArticleId_.cpp:96
TAttlist & SetAttlist(void)
Assign a value to Attlist data member.
Definition: ArticleId_.hpp:370
NCBI_NS_STD::string m_ArticleId
Definition: ArticleId_.hpp:285
NCBI_NS_NCBI::CRef< TAttlist > m_Attlist
Definition: ArticleId_.hpp:284
Uint4 m_set_State[1]
Definition: ArticleId_.hpp:283
C_Attlist TAttlist
Definition: ArticleId_.hpp:184
void Reset(void)
Reset the whole object.
Definition: ArticleId_.cpp:67
void ResetArticleId(void)
Reset ArticleId data member.
Definition: ArticleId_.cpp:110
static MDB_envinfo info
Definition: mdb_load.c:37
const GenericPointer< typename T::ValueType > T2 value
Definition: pointer.h:1227
User-defined methods of the data storage class.
BEGIN_NAMED_BASE_CLASS_INFO("ArticleId", CArticleId)
Definition: ArticleId_.cpp:122
BEGIN_NAMED_CLASS_INFO("", CArticleId_Base::C_Attlist)
Definition: ArticleId_.cpp:72
BEGIN_eutils_SCOPE BEGIN_NAMED_ENUM_IN_INFO("", CArticleId_Base::C_Attlist::, EAttlist_IdType, false)
Definition: ArticleId_.cpp:48
Modified on Fri Sep 20 14:58:29 2024 by modify_doxy.py rev. 669887