CODNameCommand Class
class CODNameCommand: public CODCommand
Changes the name of components.Defined in: OdNameCmd.h
Class Members
CODNameCommand(CODModel* pModel)
Constructor.
virtual ~CODNameCommand()
Destructor.
CString m_strName
The name to change the components to.
CMap<CODComponent*,CODComponent*,CString,CString> m_mapOldNames
A map containing the old names of the components. These are stored for undo purposes.
CString GetName() const
Gets the name that the components will be switched to.
void SetName(LPCTSTR lpszName)
Sets the name that the components will be switched to.
void ClearOldNames()
Removes all entries from the map of old names.
BOOL GetOldName(CODComponent* pComp, CString& strOldName) const
Gets the old name for a particular component.
void SetOldName(CODComponent* pComp, CString strOldName)
Sets the old name for a particular component.
virtual BOOL Execute()
Change the name of the components.
virtual BOOL Unexecute()
Restore the old names of the components.
virtual sfl::MvcCommand* Dup() const
Make a copy of this name command.
virtual void Sprint(CString& strCmd)
Print information on this command for logging purposes.