From 5bdcae9e54b70997f90320400d5e0c649c99d8e0 Mon Sep 17 00:00:00 2001 From: gka Date: Fri, 20 Mar 2020 12:13:08 +0300 Subject: [PATCH] 0031452: Impossible to get Backup of the attribute and status that attribute was modified before commit transaction Added public method returning Backup for attribute --- src/TDF/TDF_Attribute.hxx | 4 ++++ src/TDF/TDF_Attribute.lxx | 6 ++++++ 2 files changed, 10 insertions(+) diff --git a/src/TDF/TDF_Attribute.hxx b/src/TDF/TDF_Attribute.hxx index 7c85746424..8df9029e5e 100644 --- a/src/TDF/TDF_Attribute.hxx +++ b/src/TDF/TDF_Attribute.hxx @@ -282,6 +282,10 @@ public: //! Backup() method. Standard_Boolean IsBackuped() const; + //! Returns Backup attribute for current state of attribute + Standard_EXPORT Handle(TDF_Attribute) GetBackup() const; + + //! Copies the attribute contents into a new other //! attribute. It is used by Backup(). Standard_EXPORT virtual Handle(TDF_Attribute) BackupCopy() const; diff --git a/src/TDF/TDF_Attribute.lxx b/src/TDF/TDF_Attribute.lxx index 5f3efa29bf..4d4be8ecd1 100644 --- a/src/TDF/TDF_Attribute.lxx +++ b/src/TDF/TDF_Attribute.lxx @@ -59,3 +59,9 @@ inline Standard_Boolean TDF_Attribute::IsForgotten() const inline Standard_OStream& operator << (Standard_OStream& anOS, const Handle(TDF_Attribute)& anAtt) { return anAtt->Dump(anOS); } + + +inline Handle(TDF_Attribute) TDF_Attribute::GetBackup() const +{ + return myBackup; +} \ No newline at end of file -- 2.39.5