Skip to content

Commit 8d83ed2

Browse files
committed
Expose Object::getDocument() as a const public method.
1 parent 2fc6dc1 commit 8d83ed2

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

OpenSim/Common/Object.h

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -563,13 +563,14 @@ class OSIMCOMMON_API Object
563563
lost here. **/
564564
void setDocument(XMLDocument* doc) {_document=doc;}
565565

566-
/** Get a const pointer to the document (if any) associated with this
567-
object. **/
568-
const XMLDocument* getDocument() const {return _document;}
569566
/** Get a writable pointer to the document (if any) associated with this
570567
object. **/
571568
XMLDocument* updDocument() {return _document;}
572569
public:
570+
/** Get a const pointer to the document (if any) associated with this
571+
object. **/
572+
const XMLDocument* getDocument() const { return _document; }
573+
573574
/** If there is a document associated with this object then return the
574575
file name maintained by the document. Otherwise return an empty string. **/
575576
std::string getDocumentFileName() const;

0 commit comments

Comments
 (0)