瀏覽代碼

Made id getter and setter virtual

Andreas Fetzer 10 年之前
父節點
當前提交
edf5185a6f
共有 2 個文件被更改,包括 4 次插入4 次删除
  1. 2 2
      Libs/XNAT/Core/ctkXnatObject.h
  2. 2 2
      Libs/XNAT/Core/ctkXnatResource.h

+ 2 - 2
Libs/XNAT/Core/ctkXnatObject.h

@@ -49,11 +49,11 @@ public:
   virtual ~ctkXnatObject();
 
   /// Gets the global ID of the object.
-  QString id() const;
+  virtual QString id() const;
 
   /// Sets the ID of the object.
   /// @warning You must not change the ID of an existing object
-  void setId(const QString& id);
+  virtual void setId(const QString& id);
 
   /// Gets the resource URI of the object that can be used to access it through
   /// the REST API.

+ 2 - 2
Libs/XNAT/Core/ctkXnatResource.h

@@ -44,8 +44,8 @@ public:
 
   QString resourceUri() const;
 
-  QString id() const;
-  void setId(const QString &id);
+  virtual QString id() const;
+  virtual void setId(const QString &id);
 
   QString name() const;
   void setName(const QString &name);