Public Member Functions | Protected Member Functions | List of all members
ModifyOp Class Reference

Class for modifying elements. More...

#include <DgnElementSetTool.h>

Inheritance diagram for ModifyOp:
IModifyElement DgnElementSetTool DgnRegionElementTool ElementGraphicsTool LocateSubEntityTool

Public Member Functions

 ModifyOp ()
 
virtual ~ModifyOp ()
 
- Public Member Functions inherited from IModifyElement
virtual StatusInt _OnElementModify (EditElementHandleR eeh)=0
 Called to apply element modification. More...
 

Protected Member Functions

virtual void _SetWantMakeCopy (bool val) override
 Call to set copy option. More...
 
virtual void _SetWantGGLock (bool val) override
 Call to set graphic group number remap option for copy. More...
 
virtual bool _WantMakeCopy () const override
 Call to determine whether original element is being modified or copied. More...
 
virtual bool _WantCheckGGLock () const override
 Call to determine whether copied elements will have their graphic group number remapped or cleared. More...
 
virtual DgnModelRefP _GetDestinationModelRef ()
 Called to get destination model when create a copy, ModifyOp::WantMakeCopy is true. More...
 
virtual ElementCopyContextP _GetCopyContext ()
 CopyContext used by ModifyOp::OnPreElementModify call to DoCopy when ModifyOp::WantMakeCopy is true. More...
 
virtual void _ClearCopyContext ()
 Flush deferred copy-related changes and release the ElementCopyContext used by ModifyOp::OnPreElementModify, if any. More...
 
virtual StatusInt _DoOperationForModify (EditElementHandleR eeh) override
 Called to perform element modification. More...
 
virtual StatusInt _OnPreElementModify (EditElementHandleR eeh)
 Called to perform pre-modification checks/changes. More...
 
virtual void _ResetStop () override
 Called to initialize abort processing for ElementAgenda::ModifyAgenda. More...
 
virtual bool _CheckStop () override
 Called to abort processing for ElementAgenda::ModifyAgenda. More...
 

Detailed Description

Class for modifying elements.

Implemented by DgnElementSetTool to apply the tool operation to the ElementAgenda populated from the preferred ElemSource.

Remarks
Required library : DgnView<ApiNumber>.lib i.e. DgnView2.lib

Constructor & Destructor Documentation

ModifyOp ( )

References NULL.

virtual ~ModifyOp ( )
virtual

Member Function Documentation

virtual bool _CheckStop ( )
overrideprotectedvirtual

Called to abort processing for ElementAgenda::ModifyAgenda.

Returns
true to stop processing agenda when user requests abort.

Implements IModifyElement.

Reimplemented in DgnRegionElementTool.

virtual void _ClearCopyContext ( )
protectedvirtual

Flush deferred copy-related changes and release the ElementCopyContext used by ModifyOp::OnPreElementModify, if any.

virtual StatusInt _DoOperationForModify ( EditElementHandleR  eeh)
overrideprotectedvirtual

Called to perform element modification.

Element will be updated if both ModifyOp::OnPreElementModify and ModifyOp::_OnElementModify return SUCCESS.

Parameters
eehIN element to apply modification to.
Remarks
Will delete the element if SUCCESS is returned and eeh was set invalid. A valid element will be added or replaced based on return from ModifyOp::WantMakeCopy.
Returns
SUCCESS if modify was ok and element was updated.

Implements IModifyElement.

virtual ElementCopyContextP _GetCopyContext ( )
protectedvirtual

CopyContext used by ModifyOp::OnPreElementModify call to DoCopy when ModifyOp::WantMakeCopy is true.

virtual DgnModelRefP _GetDestinationModelRef ( )
protectedvirtual

Called to get destination model when create a copy, ModifyOp::WantMakeCopy is true.

Reimplemented in DgnElementSetTool.

virtual StatusInt _OnPreElementModify ( EditElementHandleR  eeh)
protectedvirtual

Called to perform pre-modification checks/changes.

Parameters
eehIN element to apply modification to.
Returns
SUCCESS if ok to proceed with modification.
Remarks
If ModifyOp::WantMakeCopy is true calls DoCopy between element source model and ModifyOp::GetDestinationModelRef. When not copying only elements from the destination model or a self-attachment are accepted.
virtual void _ResetStop ( )
overrideprotectedvirtual

Called to initialize abort processing for ElementAgenda::ModifyAgenda.

Implements IModifyElement.

Reimplemented in DgnRegionElementTool.

virtual void _SetWantGGLock ( bool  val)
overrideprotectedvirtual

Call to set graphic group number remap option for copy.

Implements IModifyElement.

virtual void _SetWantMakeCopy ( bool  val)
overrideprotectedvirtual

Call to set copy option.

Implements IModifyElement.

virtual bool _WantCheckGGLock ( ) const
overrideprotectedvirtual

Call to determine whether copied elements will have their graphic group number remapped or cleared.

Returns
true to remap graphic group numbers.

Implements IModifyElement.

virtual bool _WantMakeCopy ( ) const
overrideprotectedvirtual

Call to determine whether original element is being modified or copied.

Returns
true to copy/add modified elements.

Implements IModifyElement.


The documentation for this class was generated from the following file:

Copyright © 2017 Bentley Systems, Incorporated. All rights reserved.