NCBI C++ ToolKit
Bioseq_set_.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  * 'seqset.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
43 #include <objects/general/Date.hpp>
50 
51 BEGIN_objects_SCOPE // namespace ncbi::objects::
52 
53 
54 // generated classes
55 
57 {
58  SET_ENUM_INTERNAL_NAME("Bioseq-set", "class");
59  SET_ENUM_MODULE("NCBI-Seqset");
60  ADD_ENUM_VALUE("not-set", eClass_not_set);
61  ADD_ENUM_VALUE("nuc-prot", eClass_nuc_prot);
62  ADD_ENUM_VALUE("segset", eClass_segset);
63  ADD_ENUM_VALUE("conset", eClass_conset);
64  ADD_ENUM_VALUE("parts", eClass_parts);
65  ADD_ENUM_VALUE("gibb", eClass_gibb);
66  ADD_ENUM_VALUE("gi", eClass_gi);
67  ADD_ENUM_VALUE("genbank", eClass_genbank);
68  ADD_ENUM_VALUE("pir", eClass_pir);
69  ADD_ENUM_VALUE("pub-set", eClass_pub_set);
70  ADD_ENUM_VALUE("equiv", eClass_equiv);
71  ADD_ENUM_VALUE("swissprot", eClass_swissprot);
72  ADD_ENUM_VALUE("pdb-entry", eClass_pdb_entry);
73  ADD_ENUM_VALUE("mut-set", eClass_mut_set);
74  ADD_ENUM_VALUE("pop-set", eClass_pop_set);
75  ADD_ENUM_VALUE("phy-set", eClass_phy_set);
76  ADD_ENUM_VALUE("eco-set", eClass_eco_set);
77  ADD_ENUM_VALUE("gen-prod-set", eClass_gen_prod_set);
78  ADD_ENUM_VALUE("wgs-set", eClass_wgs_set);
79  ADD_ENUM_VALUE("named-annot", eClass_named_annot);
80  ADD_ENUM_VALUE("named-annot-prod", eClass_named_annot_prod);
81  ADD_ENUM_VALUE("read-set", eClass_read_set);
82  ADD_ENUM_VALUE("paired-end-reads", eClass_paired_end_reads);
83  ADD_ENUM_VALUE("small-genome-set", eClass_small_genome_set);
84  ADD_ENUM_VALUE("other", eClass_other);
85 }
87 
89 {
90  m_Id.Reset();
91 }
92 
94 {
95  m_Id.Reset(&value);
96 }
97 
99 {
100  if ( !m_Id )
101  m_Id.Reset(new TId());
102  return (*m_Id);
103 }
104 
106 {
107  m_Coll.Reset();
108 }
109 
111 {
112  m_Coll.Reset(&value);
113 }
114 
116 {
117  if ( !m_Coll )
118  m_Coll.Reset(new TColl());
119  return (*m_Coll);
120 }
121 
123 {
124  m_Release.erase();
125  m_set_State[0] &= ~0x300;
126 }
127 
129 {
130  m_Date.Reset();
131 }
132 
134 {
135  m_Date.Reset(&value);
136 }
137 
139 {
140  if ( !m_Date )
141  m_Date.Reset(new TDate());
142  return (*m_Date);
143 }
144 
146 {
147  m_Descr.Reset();
148 }
149 
151 {
152  m_Descr.Reset(&value);
153 }
154 
156 {
157  if ( !m_Descr )
158  m_Descr.Reset(new TDescr());
159  return (*m_Descr);
160 }
161 
163 {
164  m_Seq_set.clear();
165  m_set_State[0] &= ~0xc000;
166 }
167 
169 {
170  m_Annot.clear();
171  m_set_State[0] &= ~0x30000;
172 }
173 
175 {
176  ResetId();
177  ResetColl();
178  ResetLevel();
179  ResetClass();
180  ResetRelease();
181  ResetDate();
182  ResetDescr();
183  ResetSeq_set();
184  ResetAnnot();
185 }
186 
188 {
189  SET_CLASS_MODULE("NCBI-Seqset");
190  ADD_NAMED_REF_MEMBER("id", m_Id, CObject_id)->SetOptional();
191  ADD_NAMED_REF_MEMBER("coll", m_Coll, CDbtag)->SetOptional();
192  ADD_NAMED_STD_MEMBER("level", m_Level)->SetSetFlag(MEMBER_PTR(m_set_State[0]))->SetOptional();
193  ADD_NAMED_ENUM_MEMBER("class", m_Class, EClass)->SetDefault(new TClass(eClass_not_set))->SetSetFlag(MEMBER_PTR(m_set_State[0]))->SetOptional();
194  ADD_NAMED_STD_MEMBER("release", m_Release)->SetSetFlag(MEMBER_PTR(m_set_State[0]))->SetOptional();
195  ADD_NAMED_REF_MEMBER("date", m_Date, CDate)->SetOptional();
196  ADD_NAMED_REF_MEMBER("descr", m_Descr, CSeq_descr)->SetOptional();
197  ADD_NAMED_MEMBER("seq-set", m_Seq_set, STL_list, (STL_CRef, (CLASS, (CSeq_entry))))->SetSetFlag(MEMBER_PTR(m_set_State[0]));
198  ADD_NAMED_MEMBER("annot", m_Annot, STL_list_set, (STL_CRef, (CLASS, (CSeq_annot))))->SetSetFlag(MEMBER_PTR(m_set_State[0]))->SetOptional();
199  info->RandomOrder();
200  info->CodeVersion(22400);
201  info->DataSpec(ncbi::EDataSpec::eASN);
202 }
204 
205 // constructor
207  : m_Level(0), m_Class(eClass_not_set)
208 {
209  memset(m_set_State,0,sizeof(m_set_State));
210 }
211 
212 // destructor
214 {
215 }
216 
217 
218 
219 END_objects_SCOPE // namespace ncbi::objects::
220 
222 
BEGIN_NAMED_ENUM_IN_INFO("", CBioseq_set_Base::, EClass, false)
Definition: Bioseq_set_.cpp:56
BEGIN_NAMED_BASE_CLASS_INFO("Bioseq-set", CBioseq_set)
END_ENUM_INFO
Definition: aln_errors.cpp:58
*** Sequence Collections ******************************** * just a collection
Definition: Bioseq_set_.hpp:86
Definition: Date.hpp:53
Definition: Dbtag.hpp:53
@Seq_descr.hpp User-defined methods of the data storage class.
Definition: Seq_descr.hpp:55
Definition: Seq_entry.hpp:56
#define MEMBER_PTR(MemberName)
Definition: serialimpl.hpp:284
#define SET_ENUM_INTERNAL_NAME(OwnerName, MemberName)
Definition: serialimpl.hpp:559
#define ADD_NAMED_MEMBER(MemberAlias, MemberName, TypeMacro, TypeMacroArgs)
Definition: serialimpl.hpp:342
#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
list< CRef< CSeq_entry > > m_Seq_set
CSeq_descr TDescr
CRef< TColl > m_Coll
CRef< TDescr > m_Descr
TColl & SetColl(void)
Assign a value to Coll data member.
void ResetRelease(void)
Reset Release data member.
list< CRef< CSeq_annot > > m_Annot
void ResetLevel(void)
Reset Level data member.
void ResetSeq_set(void)
Reset Seq_set data member.
void ResetAnnot(void)
Reset Annot data member.
Uint4 m_set_State[1]
virtual ~CBioseq_set_Base(void)
void ResetClass(void)
Reset Class data member.
TDescr & SetDescr(void)
Assign a value to Descr data member.
void ResetDate(void)
Reset Date data member.
void ResetDescr(void)
Reset Descr data member.
TDate & SetDate(void)
Assign a value to Date data member.
virtual void Reset(void)
Reset the whole object.
TId & SetId(void)
Assign a value to Id data member.
Definition: Bioseq_set_.cpp:98
CRef< TId > m_Id
void ResetColl(void)
Reset Coll data member.
void ResetId(void)
Reset Id data member.
Definition: Bioseq_set_.cpp:88
CRef< TDate > m_Date
static MDB_envinfo info
Definition: mdb_load.c:37
const GenericPointer< typename T::ValueType > T2 value
Definition: pointer.h:1227
Modified on Fri Sep 20 14:57:20 2024 by modify_doxy.py rev. 669887