diff OrthancServer/OrthancRestApi/OrthancRestApi.h @ 1437:02f5a3f5c0a0

access to the REST API from Lua
author Sebastien Jodogne <s.jodogne@gmail.com>
date Tue, 30 Jun 2015 18:41:33 +0200
parents 6e7e5ed91c2d
children 1b7def486e62
line wrap: on
line diff
--- a/OrthancServer/OrthancRestApi/OrthancRestApi.h	Tue Jun 30 17:19:26 2015 +0200
+++ b/OrthancServer/OrthancRestApi/OrthancRestApi.h	Tue Jun 30 18:41:33 2015 +0200
@@ -34,12 +34,14 @@
 
 #include "../../Core/RestApi/RestApi.h"
 #include "../DicomModification.h"
-#include "../ServerContext.h"
 
 #include <set>
 
 namespace Orthanc
 {
+  class ServerContext;
+  class ServerIndex;
+
   class OrthancRestApi : public RestApi
   {
   public:
@@ -76,15 +78,9 @@
       return dynamic_cast<OrthancRestApi&>(call.GetContext());
     }
 
-    static ServerContext& GetContext(RestApiCall& call)
-    {
-      return GetApi(call).context_;
-    }
+    static ServerContext& GetContext(RestApiCall& call);
 
-    static ServerIndex& GetIndex(RestApiCall& call)
-    {
-      return GetContext(call).GetIndex();
-    }
+    static ServerIndex& GetIndex(RestApiCall& call);
 
     void AnswerStoredInstance(RestApiPostCall& call,
                               const std::string& publicId,