41 #ifndef OBJECTS_SEQEDIT_SEQEDIT_CMD_BASE_HPP
42 #define OBJECTS_SEQEDIT_SEQEDIT_CMD_BASE_HPP
48 #ifndef BEGIN_objects_SCOPE
49 # define BEGIN_objects_SCOPE BEGIN_SCOPE(objects)
50 # define END_objects_SCOPE END_SCOPE(objects)
137 virtual void Reset(
void);
140 virtual void ResetSelection(
void);
146 E_Choice Which(
void)
const;
152 void CheckSelected(E_Choice index)
const;
158 NCBI_NORETURN
void ThrowInvalidSelection(E_Choice index)
const;
166 static string SelectionName(E_Choice index);
216 bool IsAdd_id(
void)
const;
222 const TAdd_id& GetAdd_id(
void)
const;
242 bool IsRemove_id(
void)
const;
268 bool IsReset_ids(
void)
const;
294 bool IsChange_seqattr(
void)
const;
320 bool IsReset_seqattr(
void)
const;
346 bool IsChange_setattr(
void)
const;
372 bool IsReset_setattr(
void)
const;
398 bool IsAdd_descr(
void)
const;
424 bool IsSet_descr(
void)
const;
450 bool IsReset_descr(
void)
const;
476 bool IsAdd_desc(
void)
const;
482 const TAdd_desc& GetAdd_desc(
void)
const;
502 bool IsRemove_desc(
void)
const;
528 bool IsAttach_seq(
void)
const;
554 bool IsAttach_set(
void)
const;
580 bool IsReset_seqentry(
void)
const;
606 bool IsAttach_seqentry(
void)
const;
632 bool IsRemove_seqentry(
void)
const;
658 bool IsAttach_annot(
void)
const;
684 bool IsRemove_annot(
void)
const;
710 bool IsAdd_annot(
void)
const;
736 bool IsReplace_annot(
void)
const;
765 static const char*
const sm_SelectionNames[];
CSeqEdit_Cmd_AttachAnnot –.
CSeqEdit_Cmd_AttachSeqEntry –.
CSeqEdit_Cmd_AttachSeq –.
CSeqEdit_Cmd_AttachSet –.
***************************************************************
CSeqEdit_Cmd_ChangeSeqAttr –.
CSeqEdit_Cmd_ChangeSetAttr –.
CSeqEdit_Cmd_RemoveAnnot –.
CSeqEdit_Cmd_RemoveDesc –.
CSeqEdit_Cmd_RemoveSeqEntry –.
CSeqEdit_Cmd_ReplaceAnnot –.
CSeqEdit_Cmd_ResetDescr –.
CSeqEdit_Cmd_ResetSeqAttr –.
CSeqEdit_Cmd_ResetSeqEntry –.
CSeqEdit_Cmd_ResetSetAttr –.
Base class for all serializable objects.
#define END_NCBI_SCOPE
End previously defined NCBI scope.
#define BEGIN_NCBI_SCOPE
Define ncbi namespace.
#define NCBI_SEQEDIT_EXPORT
E_Choice Which(void) const
Which variant is currently selected.
bool IsRemove_annot(void) const
Check if variant Remove_annot is selected.
CSeqEdit_Cmd_ChangeSeqAttr TChange_seqattr
CSeqEdit_Cmd_RemoveAnnot TRemove_annot
CSeqEdit_Cmd_AddAnnot TAdd_annot
bool IsChange_seqattr(void) const
Check if variant Change_seqattr is selected.
bool IsAdd_desc(void) const
Check if variant Add_desc is selected.
CSeqEdit_Cmd_SetDescr TSet_descr
CSeqEdit_Cmd_ResetSeqAttr TReset_seqattr
bool IsReset_seqentry(void) const
Check if variant Reset_seqentry is selected.
bool IsReset_ids(void) const
Check if variant Reset_ids is selected.
CSeqEdit_Cmd_RemoveSeqEntry TRemove_seqentry
CSeqEdit_Cmd_ChangeSetAttr TChange_setattr
CSeqEdit_Cmd_ResetSeqEntry TReset_seqentry
bool IsSet_descr(void) const
Check if variant Set_descr is selected.
bool IsAdd_annot(void) const
Check if variant Add_annot is selected.
CSeqEdit_Cmd_AddId TAdd_id
bool IsAttach_seq(void) const
Check if variant Attach_seq is selected.
CSeqEdit_Cmd_ResetSetAttr TReset_setattr
NCBI_NS_NCBI::CSerialObject * m_object
bool IsAdd_descr(void) const
Check if variant Add_descr is selected.
bool IsReset_descr(void) const
Check if variant Reset_descr is selected.
CSeqEdit_Cmd_RemoveId TRemove_id
virtual void ResetSelection(void)
Reset the selection (set it to e_not_set).
CSeqEdit_Cmd_AttachSeq TAttach_seq
bool IsRemove_seqentry(void) const
Check if variant Remove_seqentry is selected.
bool IsAttach_seqentry(void) const
Check if variant Attach_seqentry is selected.
CSeqEdit_Cmd_AttachSeqEntry TAttach_seqentry
CSeqEdit_Cmd_AddDescr TAdd_descr
DECLARE_INTERNAL_TYPE_INFO()
bool IsAdd_id(void) const
Check if variant Add_id is selected.
CSeqEdit_Cmd_ReplaceAnnot TReplace_annot
bool IsReset_setattr(void) const
Check if variant Reset_setattr is selected.
bool IsReplace_annot(void) const
Check if variant Replace_annot is selected.
bool IsRemove_id(void) const
Check if variant Remove_id is selected.
CSeqEdit_Cmd_Base(const CSeqEdit_Cmd_Base &)
CSeqEdit_Cmd_RemoveDesc TRemove_desc
bool IsRemove_desc(void) const
Check if variant Remove_desc is selected.
void Select(E_Choice index, EResetVariant reset, CObjectMemoryPool *pool)
Select the requested variant if needed, allocating CObject variants from memory pool.
bool IsAttach_set(void) const
Check if variant Attach_set is selected.
void CheckSelected(E_Choice index) const
Verify selection, throw exception if it differs from the expected.
void DoSelect(E_Choice index, CObjectMemoryPool *pool=0)
CSeqEdit_Cmd_AttachAnnot TAttach_annot
bool IsReset_seqattr(void) const
Check if variant Reset_seqattr is selected.
CSeqEdit_Cmd_ResetDescr TReset_descr
bool IsAttach_annot(void) const
Check if variant Attach_annot is selected.
CSeqEdit_Cmd_AddDesc TAdd_desc
void Select(E_Choice index, EResetVariant reset=eDoResetVariant)
Select the requested variant if needed.
CSeqEdit_Cmd_AttachSet TAttach_set
E_ChoiceStopper
Maximum+1 value of the choice variant enumerator.
bool IsChange_setattr(void) const
Check if variant Change_setattr is selected.
CSeqEdit_Cmd_ResetIds TReset_ids
void ThrowInvalidSelection(E_Choice index) const
Throw 'InvalidSelection' exception.
CSeqEdit_Cmd_Base & operator=(const CSeqEdit_Cmd_Base &)
@ e_Remove_seqentry
Remove a seq entry from bioseq-set.
@ e_Add_descr
Add descriptors to an object.
@ e_Attach_seqentry
Attach a seq entry to bioseq-set.
@ e_Add_desc
Add a descriptor ot an object.
@ e_not_set
No variant selected.
@ e_Attach_seq
Attach a bioseq to seq entry.
@ e_Remove_id
Remove a seq-id from bioseq.
@ e_Reset_seqentry
Detach an object from seq entry.
@ e_Attach_annot
Add a compelte annotation.
@ e_Reset_setattr
Reset bioseq-set's attribute.
@ e_Reset_ids
Reset ids field of bioseq.
@ e_Add_annot
Add an annotaion object.
@ e_Remove_desc
Remove a descripor from an object.
@ e_Set_descr
Set an objects's descriptors.
@ e_Remove_annot
Remove an annotation object.
@ e_Change_setattr
Change bioseq-set's attribure.
@ e_Attach_set
Attach a bioseq-set to seq entry.
@ e_Replace_annot
Replace an annotation object.
@ e_Add_id
Add a new seq-id to bioseq.
@ e_Reset_descr
Reset an objects's descriptors.
@ e_Reset_seqattr
Reset bioseq's attribute.
@ e_Change_seqattr
Change bioseq's attribure.