diff OrthancServer/ServerEnumerations.cpp @ 3931:e6606d3ec892 transcoding

new configuration option: BuiltinDecoderTranscoderOrder
author Sebastien Jodogne <s.jodogne@gmail.com>
date Fri, 15 May 2020 09:22:31 +0200
parents 4182cde57afb
children 5d2348b39392
line wrap: on
line diff
--- a/OrthancServer/ServerEnumerations.cpp	Thu May 14 19:20:40 2020 +0200
+++ b/OrthancServer/ServerEnumerations.cpp	Fri May 15 09:22:31 2020 +0200
@@ -214,6 +214,29 @@
                              "should be \"Always\", \"Never\" or \"Answers\": " + value);
     }    
   }
+
+
+  BuiltinDecoderTranscoderOrder StringToBuiltinDecoderTranscoderOrder(const std::string& value)
+  {
+    if (value == "Before")
+    {
+      return BuiltinDecoderTranscoderOrder_Before;
+    }
+    else if (value == "After")
+    {
+      return BuiltinDecoderTranscoderOrder_After;
+    }
+    else if (value == "Disabled")
+    {
+      return BuiltinDecoderTranscoderOrder_Disabled;
+    }
+    else
+    {
+      throw OrthancException(ErrorCode_ParameterOutOfRange,
+                             "Configuration option \"BuiltinDecoderTranscoderOrder\" "
+                             "should be \"After\", \"Before\" or \"Disabled\": " + value);
+    }    
+  }
   
 
   std::string GetBasePath(ResourceType type,