NCBI C++ ToolKit
Seq_inst_.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  * 'seq.asn'.
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
42 #include <objects/seq/Seq_inst.hpp>
44 #include <objects/seq/Seq_data.hpp>
45 #include <objects/seq/Seq_ext.hpp>
46 #include <objects/seq/Seq_hist.hpp>
48 
49 BEGIN_objects_SCOPE // namespace ncbi::objects::
50 
51 
52 // generated classes
53 
55 {
56  SET_ENUM_INTERNAL_NAME("Seq-inst", "repr");
57  SET_ENUM_MODULE("NCBI-Sequence");
58  ADD_ENUM_VALUE("not-set", eRepr_not_set);
59  ADD_ENUM_VALUE("virtual", eRepr_virtual);
60  ADD_ENUM_VALUE("raw", eRepr_raw);
61  ADD_ENUM_VALUE("seg", eRepr_seg);
62  ADD_ENUM_VALUE("const", eRepr_const);
63  ADD_ENUM_VALUE("ref", eRepr_ref);
64  ADD_ENUM_VALUE("consen", eRepr_consen);
65  ADD_ENUM_VALUE("map", eRepr_map);
66  ADD_ENUM_VALUE("delta", eRepr_delta);
67  ADD_ENUM_VALUE("other", eRepr_other);
68 }
70 
72 {
73  SET_ENUM_INTERNAL_NAME("Seq-inst", "mol");
74  SET_ENUM_MODULE("NCBI-Sequence");
75  ADD_ENUM_VALUE("not-set", eMol_not_set);
76  ADD_ENUM_VALUE("dna", eMol_dna);
77  ADD_ENUM_VALUE("rna", eMol_rna);
78  ADD_ENUM_VALUE("aa", eMol_aa);
79  ADD_ENUM_VALUE("na", eMol_na);
80  ADD_ENUM_VALUE("other", eMol_other);
81 }
83 
84 BEGIN_NAMED_ENUM_IN_INFO("", CSeq_inst_Base::, ETopology, false)
85 {
86  SET_ENUM_INTERNAL_NAME("Seq-inst", "topology");
87  SET_ENUM_MODULE("NCBI-Sequence");
88  ADD_ENUM_VALUE("not-set", eTopology_not_set);
89  ADD_ENUM_VALUE("linear", eTopology_linear);
90  ADD_ENUM_VALUE("circular", eTopology_circular);
91  ADD_ENUM_VALUE("tandem", eTopology_tandem);
92  ADD_ENUM_VALUE("other", eTopology_other);
93 }
95 
97 {
98  SET_ENUM_INTERNAL_NAME("Seq-inst", "strand");
99  SET_ENUM_MODULE("NCBI-Sequence");
100  ADD_ENUM_VALUE("not-set", eStrand_not_set);
101  ADD_ENUM_VALUE("ss", eStrand_ss);
102  ADD_ENUM_VALUE("ds", eStrand_ds);
103  ADD_ENUM_VALUE("mixed", eStrand_mixed);
104  ADD_ENUM_VALUE("other", eStrand_other);
105 }
107 
109 {
110  m_Fuzz.Reset();
111 }
112 
114 {
115  m_Fuzz.Reset(&value);
116 }
117 
119 {
120  if ( !m_Fuzz )
121  m_Fuzz.Reset(new TFuzz());
122  return (*m_Fuzz);
123 }
124 
126 {
127  m_Seq_data.Reset();
128 }
129 
131 {
132  m_Seq_data.Reset(&value);
133 }
134 
136 {
137  if ( !m_Seq_data )
138  m_Seq_data.Reset(new TSeq_data());
139  return (*m_Seq_data);
140 }
141 
143 {
144  m_Ext.Reset();
145 }
146 
148 {
149  m_Ext.Reset(&value);
150 }
151 
153 {
154  if ( !m_Ext )
155  m_Ext.Reset(new TExt());
156  return (*m_Ext);
157 }
158 
160 {
161  m_Hist.Reset();
162 }
163 
165 {
166  m_Hist.Reset(&value);
167 }
168 
170 {
171  if ( !m_Hist )
172  m_Hist.Reset(new THist());
173  return (*m_Hist);
174 }
175 
177 {
178  ResetRepr();
179  ResetMol();
180  ResetLength();
181  ResetFuzz();
182  ResetTopology();
183  ResetStrand();
184  ResetSeq_data();
185  ResetExt();
186  ResetHist();
187 }
188 
190 {
191  SET_CLASS_MODULE("NCBI-Sequence");
192  ADD_NAMED_ENUM_MEMBER("repr", m_Repr, ERepr)->SetSetFlag(MEMBER_PTR(m_set_State[0]));
193  ADD_NAMED_ENUM_MEMBER("mol", m_Mol, EMol)->SetSetFlag(MEMBER_PTR(m_set_State[0]));
194  ADD_NAMED_STD_MEMBER("length", m_Length)->SetSetFlag(MEMBER_PTR(m_set_State[0]))->SetOptional();
195  ADD_NAMED_REF_MEMBER("fuzz", m_Fuzz, CInt_fuzz)->SetOptional();
196  ADD_NAMED_ENUM_MEMBER("topology", m_Topology, ETopology)->SetDefault(new TTopology(eTopology_linear))->SetSetFlag(MEMBER_PTR(m_set_State[0]))->SetOptional();
197  ADD_NAMED_ENUM_MEMBER("strand", m_Strand, EStrand)->SetSetFlag(MEMBER_PTR(m_set_State[0]))->SetOptional();
198  ADD_NAMED_REF_MEMBER("seq-data", m_Seq_data, CSeq_data)->SetOptional();
199  ADD_NAMED_REF_MEMBER("ext", m_Ext, CSeq_ext)->SetOptional();
200  ADD_NAMED_REF_MEMBER("hist", m_Hist, CSeq_hist)->SetOptional();
201  info->RandomOrder();
202  info->CodeVersion(22301);
203  info->DataSpec(ncbi::EDataSpec::eASN);
204 }
206 
207 // constructor
209  : m_Repr((ERepr)(0)), m_Mol((EMol)(0)), m_Length(0), m_Topology(eTopology_linear), m_Strand((EStrand)(0))
210 {
211  memset(m_set_State,0,sizeof(m_set_State));
212 }
213 
214 // destructor
216 {
217 }
218 
219 
220 
221 END_objects_SCOPE // namespace ncbi::objects::
222 
224 
User-defined methods of the data storage class.
User-defined methods of the data storage class.
BEGIN_NAMED_ENUM_IN_INFO("", CSeq_inst_Base::, ERepr, false)
Definition: Seq_inst_.cpp:54
BEGIN_NAMED_BASE_CLASS_INFO("Seq-inst", CSeq_inst)
Definition: Seq_inst_.cpp:189
END_ENUM_INFO
Definition: aln_errors.cpp:58
CSeq_ext –.
Definition: Seq_ext.hpp:66
CSeq_hist –.
Definition: Seq_hist.hpp:66
*** Instances of sequences ******************************* * the sequence data itself
Definition: Seq_inst_.hpp:79
char value[7]
Definition: config.c:431
EStrand
#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 ADD_NAMED_ENUM_MEMBER(MemberAlias, MemberName, EnumName)
Definition: serialimpl.hpp:351
#define ADD_ENUM_VALUE(EnumValueName, EnumValueValue)
Definition: serialimpl.hpp:562
#define END_NCBI_SCOPE
End previously defined NCBI scope.
Definition: ncbistl.hpp:103
#define BEGIN_NCBI_SCOPE
Define ncbi namespace.
Definition: ncbistl.hpp:100
virtual void Reset(void)
Reset the whole object.
Definition: Seq_inst_.cpp:176
CInt_fuzz TFuzz
Definition: Seq_inst_.hpp:148
void ResetStrand(void)
Reset Strand data member.
Definition: Seq_inst_.hpp:770
CRef< TFuzz > m_Fuzz
Definition: Seq_inst_.hpp:528
ERepr
representation class
Definition: Seq_inst_.hpp:91
void ResetMol(void)
Reset Mol data member.
Definition: Seq_inst_.hpp:605
CSeq_data TSeq_data
Definition: Seq_inst_.hpp:151
CRef< TSeq_data > m_Seq_data
Definition: Seq_inst_.hpp:531
CSeq_inst_Base(void)
Definition: Seq_inst_.cpp:208
virtual ~CSeq_inst_Base(void)
Definition: Seq_inst_.cpp:215
THist & SetHist(void)
Assign a value to Hist data member.
Definition: Seq_inst_.cpp:169
Uint4 m_set_State[1]
Definition: Seq_inst_.hpp:524
CSeq_ext TExt
Definition: Seq_inst_.hpp:152
void ResetTopology(void)
Reset Topology data member.
Definition: Seq_inst_.hpp:720
CRef< TExt > m_Ext
Definition: Seq_inst_.hpp:532
TSeq_data & SetSeq_data(void)
Assign a value to Seq_data data member.
Definition: Seq_inst_.cpp:135
void ResetHist(void)
Reset Hist data member.
Definition: Seq_inst_.cpp:159
EMol
molecule class in living organism
Definition: Seq_inst_.hpp:108
EStrand
strandedness in living organism
Definition: Seq_inst_.hpp:133
TExt & SetExt(void)
Assign a value to Ext data member.
Definition: Seq_inst_.cpp:152
void ResetLength(void)
Reset Length data member.
Definition: Seq_inst_.hpp:652
TFuzz & SetFuzz(void)
Assign a value to Fuzz data member.
Definition: Seq_inst_.cpp:118
void ResetFuzz(void)
Reset Fuzz data member.
Definition: Seq_inst_.cpp:108
void ResetExt(void)
Reset Ext data member.
Definition: Seq_inst_.cpp:142
CRef< THist > m_Hist
Definition: Seq_inst_.hpp:533
void ResetRepr(void)
Reset Repr data member.
Definition: Seq_inst_.hpp:558
CSeq_hist THist
Definition: Seq_inst_.hpp:153
void ResetSeq_data(void)
Reset Seq_data data member.
Definition: Seq_inst_.cpp:125
static MDB_envinfo info
Definition: mdb_load.c:37
Modified on Tue Dec 05 02:22:52 2023 by modify_doxy.py rev. 669887