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

Go to the SVN repository for this file.

1 /* $Id: editing_action_desc.hpp 45101 2020-05-29 20:53:24Z asztalos $
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  * Authors: Igor Filippov
27  */
28 
29 #ifndef _EDITING_ACTION_DESC_H_
30 #define _EDITING_ACTION_DESC_H_
31 
32 #include <corelib/ncbistd.hpp>
33 #include <objects/pub/Pub.hpp>
34 #include <objects/biblio/Title.hpp>
42 
45 
47 
49 {
50 public:
51  IEditingActionDesc(CSeq_entry_Handle seh, CConstRef<objects::CSeq_submit> submit, const string &name, const CSeqdesc::E_Choice subtype);
52  void SetDesc(const CSeqdesc* desc);
54 
55 protected:
56  virtual void Find(EActionType action);
57  virtual void FindRelated(EActionType action);
58  virtual void Modify(EActionType action);
59  virtual bool SameObject();
60  virtual void SwapContext(IEditingAction* source);
61 
63  const CSeqdesc* m_Desc;
65  bool m_delete;
69 };
70 
72 {
73 public:
75 protected:
76  virtual bool IsSetValue(void);
77  virtual void SetValue(const string &value);
78  virtual string GetValue(void);
79  virtual void ResetValue(void);
80 };
81 
83 {
84 public:
86 protected:
87  virtual bool IsSetValue(void);
88  virtual void SetValue(const string &value);
89  virtual string GetValue(void);
90  virtual void ResetValue(void);
91 };
92 
94 {
95 public:
97 protected:
98  virtual void Modify(EActionType action);
99  virtual bool IsSetValue(void);
100  virtual void SetValue(const string &value);
101  virtual string GetValue(void);
102  virtual void ResetValue(void);
103 private:
104  string *m_keyword;
105  bool m_erase;
106 };
107 
109 {
110 public:
112 protected:
113  virtual bool IsSetValue(void);
114  virtual void SetValue(const string &value);
115  virtual string GetValue(void);
116  virtual void ResetValue(void);
117 };
118 
120 {
121 public:
122  CEditingActionDescUserObject(CSeq_entry_Handle seh, const string &obj_type, const string &field, const bool create_multiple = false, CConstRef<objects::CSeq_submit> submit = CConstRef<objects::CSeq_submit>(NULL));
123 protected:
124  virtual bool SameObject();
125  virtual void Find(EActionType action);
126  virtual void FindRelated(EActionType action);
127  virtual void Modify(EActionType action);
128  virtual bool IsSetValue(void);
129  virtual void SetValue(const string &value);
130  virtual string GetValue(void);
131  virtual void ResetValue(void);
132 
133 private:
134  string m_type;
135  string m_field;
136  string *m_str_value;
138  double *m_real_value;
141  bool m_erase;
142 };
143 
145 {
146 public:
148 protected:
149  virtual bool IsSetValue(void);
150  virtual void SetValue(const string &value);
151  virtual string GetValue(void);
152  virtual void ResetValue(void);
153 };
154 
156 {
157 public:
159 protected:
160  virtual void Modify(EActionType action);
161  virtual bool IsSetValue(void);
162  virtual void SetValue(const string &value);
163  virtual string GetValue(void);
164  virtual void ResetValue(void);
165 private:
166  string *m_label;
167  bool m_erase;
168 };
169 
171 {
172 public:
174 protected:
175  virtual bool IsSetValue(void);
176  virtual void SetValue(const string &value);
177  virtual string GetValue(void);
178  virtual void ResetValue(void);
179 };
180 
182 {
183 public:
185 protected:
186  virtual bool IsSetValue(void);
187  virtual void SetValue(const string &value);
188  virtual string GetValue(void);
189  virtual void ResetValue(void);
190 };
191 
193 {
194 public:
196 protected:
197  virtual bool IsSetValue(void);
198  virtual void SetValue(const string &value);
199  virtual string GetValue(void);
200  virtual void ResetValue(void);
201 };
202 
204 {
205 public:
207 protected:
208  virtual void Find(EActionType action);
209  virtual void FindRelated(EActionType action);
210  virtual void Modify(EActionType action);
211  virtual bool SameObject();
212  virtual void SwapContext(IEditingAction* source);
213 
216 };
217 
219 {
220 public:
222 protected:
223  virtual bool IsSetValue(void);
224  virtual void SetValue(const string &value);
225  virtual string GetValue(void);
226  virtual void ResetValue(void);
227 };
228 
230 {
231 public:
233 protected:
234  virtual bool IsSetValue(void);
235  virtual void SetValue(const string &value);
236  virtual string GetValue(void);
237  virtual void ResetValue(void);
238 };
239 
241 {
242 public:
244 protected:
245  virtual bool IsSetValue(void);
246  virtual void SetValue(const string &value);
247  virtual string GetValue(void);
248  virtual void ResetValue(void);
249 };
250 
252 {
253 public:
254  IEditingActionDescPub(CSeq_entry_Handle seh, CConstRef<objects::CSeq_submit> submit = CConstRef<objects::CSeq_submit>(NULL), const string &name = "IEditingActionDescPub");
255 protected:
256  virtual bool SameObject();
257  virtual void SwapContext(IEditingAction* source);
259 };
260 
262 {
263 public:
265 protected:
266  virtual void Modify(EActionType action);
267  virtual bool IsSetValue(void);
268  virtual void SetValue(const string &value);
269  virtual string GetValue(void);
270  virtual void ResetValue(void);
271  virtual void SwapContext(IEditingAction* source);
272 private:
273  void GetTitles(CRef<CPub> pub, EActionType action, bool &found);
274 
275  string* m_title;
276  bool m_erase;
277 };
278 
280 {
281 public:
283 protected:
284  virtual void Modify(EActionType action);
285  virtual bool IsSetValue(void);
286  virtual void SetValue(const string &value);
287  virtual string GetValue(void);
288  virtual void ResetValue(void);
289  virtual void SwapContext(IEditingAction* source);
290 private:
291  bool m_erase;
293 };
294 
296 {
297 public:
298  IEditingActionDescAffil(CSeq_entry_Handle seh, CConstRef<objects::CSeq_submit> submit = CConstRef<objects::CSeq_submit>(NULL), const string &name = "IEditingActionDescAffil");
299 protected:
300  virtual void Modify(EActionType action);
301  virtual void SwapContext(IEditingAction* source);
302  void AddAuthList(CRef<CAuth_list> auth_list);
303 
305 };
306 
308 {
309 public:
311 protected:
312  virtual bool IsSetValue(void);
313  virtual void SetValue(const string &value);
314  virtual string GetValue(void);
315  virtual void ResetValue(void);
316 };
317 
319 {
320 public:
322 protected:
323  virtual bool IsSetValue(void);
324  virtual void SetValue(const string &value);
325  virtual string GetValue(void);
326  virtual void ResetValue(void);
327 };
328 
330 {
331 public:
333 protected:
334  virtual bool IsSetValue(void);
335  virtual void SetValue(const string &value);
336  virtual string GetValue(void);
337  virtual void ResetValue(void);
338 };
339 
341 {
342 public:
344 protected:
345  virtual bool IsSetValue(void);
346  virtual void SetValue(const string &value);
347  virtual string GetValue(void);
348  virtual void ResetValue(void);
349 };
350 
352 {
353 public:
355 protected:
356  virtual bool IsSetValue(void);
357  virtual void SetValue(const string &value);
358  virtual string GetValue(void);
359  virtual void ResetValue(void);
360 };
361 
363 {
364 public:
366 protected:
367  virtual bool IsSetValue(void);
368  virtual void SetValue(const string &value);
369  virtual string GetValue(void);
370  virtual void ResetValue(void);
371 };
372 
374 {
375 public:
377 protected:
378  virtual bool IsSetValue(void);
379  virtual void SetValue(const string &value);
380  virtual string GetValue(void);
381  virtual void ResetValue(void);
382 };
383 
385 {
386 public:
387  IEditingActionDescAuthors(CSeq_entry_Handle seh, CConstRef<objects::CSeq_submit> submit = CConstRef<objects::CSeq_submit>(NULL), const string &name = "IEditingActionDescAuthors");
388 protected:
389  virtual void Modify(EActionType action);
390  virtual void SwapContext(IEditingAction* source);
391 
393 };
394 
396 {
397 public:
399 protected:
400  virtual bool IsSetValue(void);
401  virtual void SetValue(const string &value);
402  virtual string GetValue(void);
403  virtual void ResetValue(void);
404 };
405 
407 {
408 public:
410 protected:
411  virtual bool IsSetValue(void);
412  virtual void SetValue(const string &value);
413  virtual string GetValue(void);
414  virtual void ResetValue(void);
415 };
416 
418 {
419 public:
421 protected:
422  virtual bool IsSetValue(void);
423  virtual void SetValue(const string &value);
424  virtual string GetValue(void);
425  virtual void ResetValue(void);
426 };
427 
429 {
430 public:
432 protected:
433  virtual bool IsSetValue(void);
434  virtual void SetValue(const string &value);
435  virtual string GetValue(void);
436  virtual void ResetValue(void);
437 };
438 
440 {
441 public:
443 protected:
444  virtual bool IsSetValue(void);
445  virtual void SetValue(const string &value);
446  virtual string GetValue(void);
447  virtual void ResetValue(void);
448 };
449 
451 {
452 public:
453  IEditingActionDescJournal(CSeq_entry_Handle seh, CConstRef<objects::CSeq_submit> submit = CConstRef<objects::CSeq_submit>(NULL), const string &name = "IEditingActionDescJournal");
454 protected:
455  virtual void Modify(EActionType action);
456 
459 private:
460  void GetImprintOrCitgen(CPub& pub);
461 };
462 
464 {
465 public:
467 protected:
468  virtual bool IsSetValue(void);
469  virtual void SetValue(const string &value);
470  virtual string GetValue(void);
471  virtual void ResetValue(void);
472 };
473 
475 {
476 public:
478 protected:
479  virtual bool IsSetValue(void);
480  virtual void SetValue(const string &value);
481  virtual string GetValue(void);
482  virtual void ResetValue(void);
483 };
484 
486 {
487 public:
489 protected:
490  virtual bool IsSetValue(void);
491  virtual void SetValue(const string &value);
492  virtual string GetValue(void);
493  virtual void ResetValue(void);
494 };
495 
497 {
498 public:
500 protected:
501  virtual bool IsSetValue(void);
502  virtual void SetValue(const string &value);
503  virtual string GetValue(void);
504  virtual void ResetValue(void);
505 };
506 
508 {
509 public:
511 protected:
512  virtual bool IsSetValue(void);
513  virtual void SetValue(const string &value);
514  virtual string GetValue(void);
515  virtual void ResetValue(void);
516 };
517 
519 {
520 public:
522 protected:
523  virtual void Modify(EActionType action);
524  virtual void SwapContext(IEditingAction* source);
525  virtual bool IsSetValue(void);
526  virtual void SetValue(const string &value);
527  virtual string GetValue(void);
528  virtual void ResetValue(void);
529 
531 };
532 
534 {
535 public:
537 protected:
538  virtual void Find(EActionType action);
539  virtual void FindRelated(EActionType action);
540  virtual void Modify(EActionType action);
541  virtual bool IsSetValue(void);
542  virtual void SetValue(const string &value);
543  virtual string GetValue(void);
544  virtual void ResetValue(void);
545 
546 private:
547  string m_type;
548  string m_field;
549  string *m_str_value;
552 };
553 
555 {
556 public:
558 protected:
559  virtual void Find(EActionType action);
560  virtual void FindRelated(EActionType action);
561  virtual void Modify(EActionType action);
562  virtual bool IsSetValue(void);
563  virtual void SetValue(const string &value);
564  virtual string GetValue(void);
565  virtual void ResetValue(void);
566 
567 private:
568  string m_type;
569  string m_field;
570  string *m_str_value;
571 };
572 
574 
576 
577 #endif
578  // _EDITING_ACTION_DESC_H_
@Affil.hpp User-defined methods of the data storage class.
Definition: Affil.hpp:56
@Auth_list.hpp User-defined methods of the data storage class.
Definition: Auth_list.hpp:57
CBioseq_Handle –.
CEditingActionDescAffil(CSeq_entry_Handle seh, CConstRef< objects::CSeq_submit > submit=CConstRef< objects::CSeq_submit >(NULL))
virtual void SetValue(const string &value)
virtual string GetValue(void)
CEditingActionDescAuthorConsortium(CSeq_entry_Handle seh, CConstRef< objects::CSeq_submit > submit=CConstRef< objects::CSeq_submit >(NULL))
virtual void SetValue(const string &value)
CEditingActionDescAuthorFirstName(CSeq_entry_Handle seh, CConstRef< objects::CSeq_submit > submit=CConstRef< objects::CSeq_submit >(NULL))
virtual void SetValue(const string &value)
CEditingActionDescAuthorInitials(CSeq_entry_Handle seh, CConstRef< objects::CSeq_submit > submit=CConstRef< objects::CSeq_submit >(NULL))
virtual void SetValue(const string &value)
CEditingActionDescAuthorLastName(CSeq_entry_Handle seh, CConstRef< objects::CSeq_submit > submit=CConstRef< objects::CSeq_submit >(NULL))
virtual void SetValue(const string &value)
CEditingActionDescAuthorNameList(CSeq_entry_Handle seh, CConstRef< objects::CSeq_submit > submit=CConstRef< objects::CSeq_submit >(NULL))
virtual void SwapContext(IEditingAction *source)
virtual void SetValue(const string &value)
virtual void Modify(EActionType action)
virtual void SetValue(const string &value)
CEditingActionDescAuthorSuffix(CSeq_entry_Handle seh, CConstRef< objects::CSeq_submit > submit=CConstRef< objects::CSeq_submit >(NULL))
virtual void SetValue(const string &value)
virtual string GetValue(void)
CEditingActionDescCity(CSeq_entry_Handle seh, CConstRef< objects::CSeq_submit > submit=CConstRef< objects::CSeq_submit >(NULL))
CEditingActionDescCommentDescriptor(CSeq_entry_Handle seh, CConstRef< objects::CSeq_submit > submit=CConstRef< objects::CSeq_submit >(NULL))
virtual void SetValue(const string &value)
CEditingActionDescComment(CSeq_entry_Handle seh, CConstRef< objects::CSeq_submit > submit=CConstRef< objects::CSeq_submit >(NULL))
virtual void Find(EActionType action)
virtual void FindRelated(EActionType action)
virtual void SetValue(const string &value)
virtual void Modify(EActionType action)
CEditingActionDescCountry(CSeq_entry_Handle seh, CConstRef< objects::CSeq_submit > submit=CConstRef< objects::CSeq_submit >(NULL))
virtual void SetValue(const string &value)
CEditingActionDescDefline(CSeq_entry_Handle seh, CConstRef< objects::CSeq_submit > submit=CConstRef< objects::CSeq_submit >(NULL))
virtual void SetValue(const string &value)
CEditingActionDescDepartment(CSeq_entry_Handle seh, CConstRef< objects::CSeq_submit > submit=CConstRef< objects::CSeq_submit >(NULL))
virtual void SetValue(const string &value)
virtual void SetValue(const string &value)
virtual string GetValue(void)
CEditingActionDescEmail(CSeq_entry_Handle seh, CConstRef< objects::CSeq_submit > submit=CConstRef< objects::CSeq_submit >(NULL))
CEditingActionDescGenomeProjectId(CSeq_entry_Handle seh, CConstRef< objects::CSeq_submit > submit=CConstRef< objects::CSeq_submit >(NULL))
virtual void SetValue(const string &value)
virtual string GetValue(void)
CEditingActionDescIssue(CSeq_entry_Handle seh, CConstRef< objects::CSeq_submit > submit=CConstRef< objects::CSeq_submit >(NULL))
virtual void SetValue(const string &value)
virtual void SetValue(const string &value)
CEditingActionDescJournal(CSeq_entry_Handle seh, CConstRef< objects::CSeq_submit > submit=CConstRef< objects::CSeq_submit >(NULL))
CEditingActionDescKeyword(CSeq_entry_Handle seh, CConstRef< objects::CSeq_submit > submit=CConstRef< objects::CSeq_submit >(NULL))
virtual void Modify(EActionType action)
virtual void SetValue(const string &value)
CEditingActionDescLocalId(CSeq_entry_Handle seh, CConstRef< objects::CSeq_submit > submit=CConstRef< objects::CSeq_submit >(NULL))
virtual void SetValue(const string &value)
virtual void Find(EActionType action)
virtual void Modify(EActionType action)
virtual void FindRelated(EActionType action)
virtual void SetValue(const string &value)
virtual string GetValue(void)
CEditingActionDescPages(CSeq_entry_Handle seh, CConstRef< objects::CSeq_submit > submit=CConstRef< objects::CSeq_submit >(NULL))
CEditingActionDescPubPmid(CSeq_entry_Handle seh, CConstRef< objects::CSeq_submit > submit=CConstRef< objects::CSeq_submit >(NULL))
virtual void SetValue(const string &value)
virtual void SwapContext(IEditingAction *source)
virtual void Modify(EActionType action)
virtual void Modify(EActionType action)
virtual void SwapContext(IEditingAction *source)
void GetTitles(CRef< CPub > pub, EActionType action, bool &found)
virtual void SetValue(const string &value)
CEditingActionDescPubTitle(CSeq_entry_Handle seh, CConstRef< objects::CSeq_submit > submit=CConstRef< objects::CSeq_submit >(NULL))
CEditingActionDescState(CSeq_entry_Handle seh, CConstRef< objects::CSeq_submit > submit=CConstRef< objects::CSeq_submit >(NULL))
virtual string GetValue(void)
virtual void SetValue(const string &value)
virtual void SetValue(const string &value)
CEditingActionDescStatus(CSeq_entry_Handle seh, CConstRef< objects::CSeq_submit > submit=CConstRef< objects::CSeq_submit >(NULL))
CEditingActionDescStreet(CSeq_entry_Handle seh, CConstRef< objects::CSeq_submit > submit=CConstRef< objects::CSeq_submit >(NULL))
virtual void SetValue(const string &value)
CEditingActionDescStructCommDbName(CSeq_entry_Handle seh, CConstRef< objects::CSeq_submit > submit=CConstRef< objects::CSeq_submit >(NULL))
virtual void SetValue(const string &value)
virtual void SetValue(const string &value)
virtual void Modify(EActionType action)
CEditingActionDescStructCommFieldName(CSeq_entry_Handle seh, CConstRef< objects::CSeq_submit > submit=CConstRef< objects::CSeq_submit >(NULL))
virtual void SetValue(const string &value)
CEditingActionDescUserObject(CSeq_entry_Handle seh, const string &obj_type, const string &field, const bool create_multiple=false, CConstRef< objects::CSeq_submit > submit=CConstRef< objects::CSeq_submit >(NULL))
virtual void FindRelated(EActionType action)
virtual void Modify(EActionType action)
virtual void Find(EActionType action)
virtual void SetValue(const string &value)
CEditingActionDescVolume(CSeq_entry_Handle seh, CConstRef< objects::CSeq_submit > submit=CConstRef< objects::CSeq_submit >(NULL))
CEditingActionMolInfoClass(CSeq_entry_Handle seh, CConstRef< objects::CSeq_submit > submit=CConstRef< objects::CSeq_submit >(NULL))
virtual void SetValue(const string &value)
CEditingActionMolInfoCompletedness(CSeq_entry_Handle seh, CConstRef< objects::CSeq_submit > submit=CConstRef< objects::CSeq_submit >(NULL))
virtual void SetValue(const string &value)
virtual void SetValue(const string &value)
CEditingActionMolInfoMolecule(CSeq_entry_Handle seh, CConstRef< objects::CSeq_submit > submit=CConstRef< objects::CSeq_submit >(NULL))
CEditingActionMolInfoStrand(CSeq_entry_Handle seh, CConstRef< objects::CSeq_submit > submit=CConstRef< objects::CSeq_submit >(NULL))
virtual void SetValue(const string &value)
CEditingActionMolInfoTechnique(CSeq_entry_Handle seh, CConstRef< objects::CSeq_submit > submit=CConstRef< objects::CSeq_submit >(NULL))
virtual void SetValue(const string &value)
virtual void SetValue(const string &value)
CEditingActionMolInfoTopology(CSeq_entry_Handle seh, CConstRef< objects::CSeq_submit > submit=CConstRef< objects::CSeq_submit >(NULL))
CImprint –.
Definition: Imprint.hpp:66
Definition: Pub.hpp:56
CSeq_entry_Handle –.
virtual void Modify(EActionType action)
IEditingActionDescAffil(CSeq_entry_Handle seh, CConstRef< objects::CSeq_submit > submit=CConstRef< objects::CSeq_submit >(NULL), const string &name="IEditingActionDescAffil")
void AddAuthList(CRef< CAuth_list > auth_list)
virtual void SwapContext(IEditingAction *source)
virtual void SwapContext(IEditingAction *source)
virtual void Modify(EActionType action)
IEditingActionDescAuthors(CSeq_entry_Handle seh, CConstRef< objects::CSeq_submit > submit=CConstRef< objects::CSeq_submit >(NULL), const string &name="IEditingActionDescAuthors")
IEditingActionDescJournal(CSeq_entry_Handle seh, CConstRef< objects::CSeq_submit > submit=CConstRef< objects::CSeq_submit >(NULL), const string &name="IEditingActionDescJournal")
virtual void Modify(EActionType action)
IEditingActionDescPub(CSeq_entry_Handle seh, CConstRef< objects::CSeq_submit > submit=CConstRef< objects::CSeq_submit >(NULL), const string &name="IEditingActionDescPub")
virtual void SwapContext(IEditingAction *source)
CBioseq_Handle GetBioseqHandle()
CSeqdesc::E_Choice m_subtype
virtual void FindRelated(EActionType action)
void SetDesc(const CSeqdesc *desc)
CRef< CSeqdesc > m_EditedDesc
CSeq_entry_Handle m_DescContext
virtual void Modify(EActionType action)
IEditingActionDesc(CSeq_entry_Handle seh, CConstRef< objects::CSeq_submit > submit, const string &name, const CSeqdesc::E_Choice subtype)
virtual void Find(EActionType action)
const CSeqdesc * m_Desc
virtual void SwapContext(IEditingAction *source)
virtual void FindRelated(EActionType action)
virtual void SwapContext(IEditingAction *source)
virtual void Modify(EActionType action)
CRef< CSeq_inst > m_EditedInst
IEditingActionInst(CSeq_entry_Handle seh, const string &name, CConstRef< objects::CSeq_submit > submit=CConstRef< objects::CSeq_submit >(NULL))
virtual void Find(EActionType action)
Include a standard set of the NCBI C++ Toolkit most basic headers.
USING_SCOPE(objects)
IEditingActionDesc * CreateActionDesc(CSeq_entry_Handle seh, const string &field, CConstRef< objects::CSeq_submit > submit=CConstRef< objects::CSeq_submit >(NULL))
#define NULL
Definition: ncbistd.hpp:225
#define END_NCBI_SCOPE
End previously defined NCBI scope.
Definition: ncbistl.hpp:103
#define BEGIN_NCBI_SCOPE
Define ncbi namespace.
Definition: ncbistl.hpp:100
E_Choice
Choice variants.
Definition: Seqdesc_.hpp:109
const GenericPointer< typename T::ValueType > T2 value
Definition: pointer.h:1227
const CharType(& source)[N]
Definition: pointer.h:1149
User-defined methods of the data storage class.
Modified on Thu Jul 11 18:00:23 2024 by modify_doxy.py rev. 669887