NCBI C++ ToolKit
PC_AssayPanel_.hpp
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  */
27 
28 /// @file PC_AssayPanel_.hpp
29 /// Data storage class.
30 ///
31 /// This file was generated by application DATATOOL
32 /// using the following specifications:
33 /// <a href="/IEB/ToolBox/CPP_DOC/lxr/source/src/objects/pcassay/pcassay.asn">pcassay.asn</a>
34 /// and additional tune-up parameters:
35 /// <a href="/IEB/ToolBox/CPP_DOC/lxr/source/src/objects/pcassay/pcassay.def">pcassay.def</a>
36 ///
37 /// ATTENTION:
38 /// Don't edit or commit this file into CVS as this file will
39 /// be overridden (by DATATOOL) without warning!
40 
41 #ifndef OBJECTS_PCASSAY_PC_ASSAYPANEL_BASE_HPP
42 #define OBJECTS_PCASSAY_PC_ASSAYPANEL_BASE_HPP
43 
44 // standard includes
45 #include <serial/serialbase.hpp>
46 
47 // generated includes
48 #include <list>
49 #include <string>
50 
52 
53 #ifndef BEGIN_objects_SCOPE
54 # define BEGIN_objects_SCOPE BEGIN_SCOPE(objects)
55 # define END_objects_SCOPE END_SCOPE(objects)
56 #endif
57 BEGIN_objects_SCOPE // namespace ncbi::objects::
58 
59 
60 // forward declarations
62 
63 
64 // generated classes
65 
66 
67 /** @addtogroup dataspec_NCBI_PCAssay
68  *
69  * @{
70  */
71 
72 /////////////////////////////////////////////////////////////////////////////
73 /// Description for Panel Assay
74 /// Describe general information about the panel, and link to information for each panel member
75 ///
76 /// CPC_AssayPanel_Base --
77 ///
78 
80 {
82 public:
83  // constructor
84  CPC_AssayPanel_Base(void);
85  // destructor
86  virtual ~CPC_AssayPanel_Base(void);
87 
88  // type info
90 
91  // types
92  typedef string TName;
93  typedef string TDescr;
94  typedef list< CRef< CPC_AssayPanelMember > > TMember;
95 
96  // member index
97  enum class E_memberIndex {
98  e__allMandatory = 0,
99  e_name,
100  e_descr,
101  e_member
102  };
104 
105  // getters
106  // setters
107 
108  /// short name for the panel, such as 'Kinase Profiling'
109  /// Check if a value has been assigned to Name data member.
110  ///
111  /// Data member Name is mandatory;
112  /// its type is defined as 'typedef string TName'
113  /// @return
114  /// - true, if a value has been assigned.
115  /// - false, otherwise.
116  bool IsSetName(void) const;
117 
118  /// Check if it is safe to call GetName method.
119  ///
120  /// @return
121  /// - true, if the data member is getatable.
122  /// - false, otherwise.
123  bool CanGetName(void) const;
124 
125  /// Reset Name data member.
126  void ResetName(void);
127 
128  /// Get the Name member data.
129  ///
130  /// @return
131  /// Reference to the member data.
132  const TName& GetName(void) const;
133 
134  /// Assign a value to Name data member.
135  ///
136  /// @param value
137  /// Value to assign
138  void SetName(const TName& value);
139  void SetName(TName&& value);
140 
141  /// Assign a value to Name data member.
142  ///
143  /// @return
144  /// Reference to the data value.
145  TName& SetName(void);
146 
147  /// short description of this panel
148  /// Check if a value has been assigned to Descr data member.
149  ///
150  /// Data member Descr is optional;
151  /// its type is defined as 'typedef string TDescr'
152  /// @return
153  /// - true, if a value has been assigned.
154  /// - false, otherwise.
155  bool IsSetDescr(void) const;
156 
157  /// Check if it is safe to call GetDescr method.
158  ///
159  /// @return
160  /// - true, if the data member is getatable.
161  /// - false, otherwise.
162  bool CanGetDescr(void) const;
163 
164  /// Reset Descr data member.
165  void ResetDescr(void);
166 
167  /// Get the Descr member data.
168  ///
169  /// @return
170  /// Reference to the member data.
171  const TDescr& GetDescr(void) const;
172 
173  /// Assign a value to Descr data member.
174  ///
175  /// @param value
176  /// Value to assign
177  void SetDescr(const TDescr& value);
178  void SetDescr(TDescr&& value);
179 
180  /// Assign a value to Descr data member.
181  ///
182  /// @return
183  /// Reference to the data value.
184  TDescr& SetDescr(void);
185 
186  /// store panel member information
187  /// Check if a value has been assigned to Member data member.
188  ///
189  /// Data member Member is optional;
190  /// its type is defined as 'typedef list< CRef< CPC_AssayPanelMember > > TMember'
191  /// @return
192  /// - true, if a value has been assigned.
193  /// - false, otherwise.
194  bool IsSetMember(void) const;
195 
196  /// Check if it is safe to call GetMember method.
197  ///
198  /// @return
199  /// - true, if the data member is getatable.
200  /// - false, otherwise.
201  bool CanGetMember(void) const;
202 
203  /// Reset Member data member.
204  void ResetMember(void);
205 
206  /// Get the Member member data.
207  ///
208  /// @return
209  /// Reference to the member data.
210  const TMember& GetMember(void) const;
211 
212  /// Assign a value to Member data member.
213  ///
214  /// @return
215  /// Reference to the data value.
216  TMember& SetMember(void);
217 
218  /// Reset the whole object
219  virtual void Reset(void);
220 
221 
222 private:
223  // Prohibit copy constructor and assignment operator
226 
227  // data
228  Uint4 m_set_State[1];
229  string m_Name;
230  string m_Descr;
231  list< CRef< CPC_AssayPanelMember > > m_Member;
232 };
233 
234 /* @} */
235 
236 
237 
238 
239 
240 ///////////////////////////////////////////////////////////
241 ///////////////////// inline methods //////////////////////
242 ///////////////////////////////////////////////////////////
243 inline
245 {
246  return ((m_set_State[0] & 0x3) != 0);
247 }
248 
249 inline
251 {
252  return IsSetName();
253 }
254 
255 inline
257 {
258  if (!CanGetName()) {
259  ThrowUnassigned(0);
260  }
261  return m_Name;
262 }
263 
264 inline
266 {
267  m_Name = value;
268  m_set_State[0] |= 0x3;
269 }
270 
271 inline
273 {
274  m_Name = std::forward<CPC_AssayPanel_Base::TName>(value);
275  m_set_State[0] |= 0x3;
276 }
277 
278 inline
280 {
281 #ifdef _DEBUG
282  if (!IsSetName()) {
284  }
285 #endif
286  m_set_State[0] |= 0x1;
287  return m_Name;
288 }
289 
290 inline
292 {
293  return ((m_set_State[0] & 0xc) != 0);
294 }
295 
296 inline
298 {
299  return IsSetDescr();
300 }
301 
302 inline
304 {
305  if (!CanGetDescr()) {
306  ThrowUnassigned(1);
307  }
308  return m_Descr;
309 }
310 
311 inline
313 {
314  m_Descr = value;
315  m_set_State[0] |= 0xc;
316 }
317 
318 inline
320 {
321  m_Descr = std::forward<CPC_AssayPanel_Base::TDescr>(value);
322  m_set_State[0] |= 0xc;
323 }
324 
325 inline
327 {
328 #ifdef _DEBUG
329  if (!IsSetDescr()) {
331  }
332 #endif
333  m_set_State[0] |= 0x4;
334  return m_Descr;
335 }
336 
337 inline
339 {
340  return ((m_set_State[0] & 0x30) != 0);
341 }
342 
343 inline
345 {
346  return true;
347 }
348 
349 inline
351 {
352  return m_Member;
353 }
354 
355 inline
357 {
358  m_set_State[0] |= 0x10;
359  return m_Member;
360 }
361 
362 ///////////////////////////////////////////////////////////
363 ////////////////// end of inline methods //////////////////
364 ///////////////////////////////////////////////////////////
365 
366 
367 
368 
369 
370 END_objects_SCOPE // namespace ncbi::objects::
371 
373 
374 
375 #endif // OBJECTS_PCASSAY_PC_ASSAYPANEL_BASE_HPP
static TObjectPtr GetMember(const CMemberInfo *memberInfo, TObjectPtr object)
Definition: choice.cpp:181
CPC_AssayPanelMember –.
Description for Panel Assay Describe general information about the panel, and link to information for...
Base class for all serializable objects.
Definition: serialbase.hpp:150
void ThrowUnassigned(TMemberIndex index) const
static string UnassignedString(void)
Definition: serialbase.hpp:175
uint32_t Uint4
4-byte (32-bit) unsigned integer
Definition: ncbitype.h:103
#define END_NCBI_SCOPE
End previously defined NCBI scope.
Definition: ncbistl.hpp:103
#define BEGIN_NCBI_SCOPE
Define ncbi namespace.
Definition: ncbistl.hpp:100
#define NCBI_PCASSAY_EXPORT
Definition: ncbi_export.h:680
TMember & SetMember(void)
Assign a value to Member data member.
CPC_AssayPanel_Base & operator=(const CPC_AssayPanel_Base &)
const TDescr & GetDescr(void) const
Get the Descr member data.
bool CanGetDescr(void) const
Check if it is safe to call GetDescr method.
CSerialObject Tparent
const TMember & GetMember(void) const
Get the Member member data.
Tparent::CMemberIndex< E_memberIndex, 4 > TmemberIndex
bool IsSetMember(void) const
store panel member information Check if a value has been assigned to Member data member.
bool IsSetName(void) const
short name for the panel, such as 'Kinase Profiling' Check if a value has been assigned to Name data ...
TDescr & SetDescr(void)
Assign a value to Descr data member.
list< CRef< CPC_AssayPanelMember > > TMember
const TName & GetName(void) const
Get the Name member data.
bool CanGetName(void) const
Check if it is safe to call GetName method.
CPC_AssayPanel_Base(const CPC_AssayPanel_Base &)
list< CRef< CPC_AssayPanelMember > > m_Member
bool CanGetMember(void) const
Check if it is safe to call GetMember method.
bool IsSetDescr(void) const
short description of this panel Check if a value has been assigned to Descr data member.
TName & SetName(void)
Assign a value to Name data member.
const GenericPointer< typename T::ValueType > T2 value
Definition: pointer.h:1227
Modified on Fri Sep 20 14:57:41 2024 by modify_doxy.py rev. 669887