0029621: Application Framework - Impossible to attach existing tessellation to XCAFDo...
[occt.git] / src / XCAFDoc / XCAFDoc_Note.hxx
index 736e6f1..16a77fa 100644 (file)
@@ -1,6 +1,4 @@
-// Created on: 2017-02-10
-// Created by: Sergey NIKONOV
-// Copyright (c) 2000-2017 OPEN CASCADE SAS
+// Copyright (c) 2017-2018 OPEN CASCADE SAS
 //
 // This file is part of Open CASCADE Technology software library.
 //
 #include <OSD_File.hxx>
 #include <TDF_Attribute.hxx>
 #include <TDF_LabelSequence.hxx>
+#include <XCAFNoteObjects_NoteObject.hxx>
 
 class Standard_GUID;
 class TDF_RelocationTable;
 
-class XCAFDoc_Note;
-DEFINE_STANDARD_HANDLE(XCAFDoc_Note, TDF_Attribute)
-
 //! A base note attribute.
 //! Any note contains the name of the user created the note
 //! and the creation timestamp.
@@ -49,17 +45,23 @@ public:
   //! \param [in] theTimeStamp - timestamp of the note.
   //! \return A handle to the attribute instance.
   Standard_EXPORT void Set(const TCollection_ExtendedString& theUserName,
-    const TCollection_ExtendedString& theTimeStamp);
+                           const TCollection_ExtendedString& theTimeStamp);
 
   //! Returns the user name, who created the note.
-  Standard_EXPORT const TCollection_ExtendedString& UserName() const;
+  const TCollection_ExtendedString& UserName() const { return myUserName; }
 
   //! Returns the timestamp of the note.
-  Standard_EXPORT const TCollection_ExtendedString& TimeStamp() const;
+  const TCollection_ExtendedString& TimeStamp() const { return myTimeStamp; }
 
   //! Checks if the note isn't linked to annotated items.
   Standard_EXPORT Standard_Boolean IsOrphan() const;
 
+  //! Returns auxiliary data object
+  Standard_EXPORT Handle(XCAFNoteObjects_NoteObject) GetObject() const;
+
+  //! Updates auxiliary data
+  Standard_EXPORT void SetObject(const Handle(XCAFNoteObjects_NoteObject)& theObject);
+
 public:
 
   // Overrides TDF_Attribute virtuals
@@ -79,4 +81,6 @@ private:
   TCollection_ExtendedString myTimeStamp; ///< Timestamp, when the note was created.
 };
 
+DEFINE_STANDARD_HANDLE(XCAFDoc_Note, TDF_Attribute)
+
 #endif // _XCAFDoc_Note_HeaderFile