annotate Sources/Autogenerated/sdk_OrthancPluginRestOutput.methods.h @ 227:9574f06d8588 default tip

todo
author Alain Mazy <am@orthanc.team>
date Tue, 24 Sep 2024 08:54:11 +0200
parents 3678a028f1f6
children
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
219
3678a028f1f6 making the project REUSE-compliant
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 186
diff changeset
1 /**
3678a028f1f6 making the project REUSE-compliant
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 186
diff changeset
2 * SPDX-FileCopyrightText: 2020-2023 Osimis S.A., 2024-2024 Orthanc Team SRL, 2021-2024 Sebastien Jodogne, ICTEAM UCLouvain
3678a028f1f6 making the project REUSE-compliant
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 186
diff changeset
3 * SPDX-License-Identifier: AGPL-3.0-or-later
3678a028f1f6 making the project REUSE-compliant
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 186
diff changeset
4 */
3678a028f1f6 making the project REUSE-compliant
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 186
diff changeset
5
186
55473de7694f added warning about auto-generated files
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 184
diff changeset
6 /**
55473de7694f added warning about auto-generated files
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 184
diff changeset
7 * Python plugin for Orthanc
55473de7694f added warning about auto-generated files
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 184
diff changeset
8 * Copyright (C) 2020-2023 Osimis S.A., Belgium
55473de7694f added warning about auto-generated files
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 184
diff changeset
9 * Copyright (C) 2024-2024 Orthanc Team SRL, Belgium
55473de7694f added warning about auto-generated files
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 184
diff changeset
10 * Copyright (C) 2021-2024 Sebastien Jodogne, ICTEAM UCLouvain, Belgium
55473de7694f added warning about auto-generated files
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 184
diff changeset
11 *
55473de7694f added warning about auto-generated files
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 184
diff changeset
12 * This program is free software: you can redistribute it and/or
55473de7694f added warning about auto-generated files
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 184
diff changeset
13 * modify it under the terms of the GNU Affero General Public License
55473de7694f added warning about auto-generated files
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 184
diff changeset
14 * as published by the Free Software Foundation, either version 3 of
55473de7694f added warning about auto-generated files
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 184
diff changeset
15 * the License, or (at your option) any later version.
55473de7694f added warning about auto-generated files
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 184
diff changeset
16 *
55473de7694f added warning about auto-generated files
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 184
diff changeset
17 * This program is distributed in the hope that it will be useful, but
55473de7694f added warning about auto-generated files
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 184
diff changeset
18 * WITHOUT ANY WARRANTY; without even the implied warranty of
55473de7694f added warning about auto-generated files
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 184
diff changeset
19 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
55473de7694f added warning about auto-generated files
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 184
diff changeset
20 * Affero General Public License for more details.
55473de7694f added warning about auto-generated files
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 184
diff changeset
21 *
55473de7694f added warning about auto-generated files
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 184
diff changeset
22 * You should have received a copy of the GNU Affero General Public License
55473de7694f added warning about auto-generated files
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 184
diff changeset
23 * along with this program. If not, see <http://www.gnu.org/licenses/>.
55473de7694f added warning about auto-generated files
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 184
diff changeset
24 **/
55473de7694f added warning about auto-generated files
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 184
diff changeset
25
55473de7694f added warning about auto-generated files
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 184
diff changeset
26
55473de7694f added warning about auto-generated files
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 184
diff changeset
27 // WARNING: Auto-generated file. Do not modify it by hand.
55473de7694f added warning about auto-generated files
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 184
diff changeset
28
55473de7694f added warning about auto-generated files
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 184
diff changeset
29
129
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
30 // Actual implementation of the methods
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
31 static PyObject *sdk_OrthancPluginRestOutput_OrthancPluginAnswerBuffer(
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
32 sdk_OrthancPluginRestOutput_Object* self, PyObject *args)
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
33 {
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
34 PythonLock::LogCall("Calling method OrthancPluginAnswerBuffer() on object of class OrthancPluginRestOutput");
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
35
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
36 if (self->object_ == NULL)
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
37 {
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
38 PyErr_SetString(PyExc_ValueError, "Invalid object");
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
39 return NULL;
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
40 }
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
41
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
42 Py_buffer arg0;
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
43 const char* arg2 = NULL;
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
44
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
45 if (!PyArg_ParseTuple(args, "s*s", &arg0, &arg2))
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
46 {
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
47 PyErr_SetString(PyExc_TypeError, "Bad types for the arguments (2 arguments expected)");
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
48 return NULL;
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
49 }
174
e9be3c9294d4 [IMPORTANT] replaced old auto-generated code with Java code model
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 149
diff changeset
50
184
f34f3a149c22 added class PythonThreadsAllower
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 178
diff changeset
51 {
f34f3a149c22 added class PythonThreadsAllower
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 178
diff changeset
52 PythonThreadsAllower allower;
f34f3a149c22 added class PythonThreadsAllower
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 178
diff changeset
53 OrthancPluginAnswerBuffer(OrthancPlugins::GetGlobalContext(), self->object_, arg0.buf, arg0.len, arg2);
f34f3a149c22 added class PythonThreadsAllower
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 178
diff changeset
54 }
129
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
55 PyBuffer_Release(&arg0);
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
56
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
57 Py_INCREF(Py_None);
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
58 return Py_None;
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
59 }
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
60
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
61 static PyObject *sdk_OrthancPluginRestOutput_OrthancPluginCompressAndAnswerPngImage(
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
62 sdk_OrthancPluginRestOutput_Object* self, PyObject *args)
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
63 {
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
64 PythonLock::LogCall("Calling method OrthancPluginCompressAndAnswerPngImage() on object of class OrthancPluginRestOutput");
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
65
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
66 if (self->object_ == NULL)
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
67 {
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
68 PyErr_SetString(PyExc_ValueError, "Invalid object");
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
69 return NULL;
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
70 }
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
71
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
72 long int arg0 = 0;
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
73 unsigned long arg1 = 0;
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
74 unsigned long arg2 = 0;
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
75 unsigned long arg3 = 0;
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
76 Py_buffer arg4;
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
77
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
78 if (!PyArg_ParseTuple(args, "lkkks*", &arg0, &arg1, &arg2, &arg3, &arg4))
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
79 {
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
80 PyErr_SetString(PyExc_TypeError, "Bad types for the arguments (5 arguments expected)");
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
81 return NULL;
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
82 }
174
e9be3c9294d4 [IMPORTANT] replaced old auto-generated code with Java code model
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 149
diff changeset
83
184
f34f3a149c22 added class PythonThreadsAllower
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 178
diff changeset
84 {
f34f3a149c22 added class PythonThreadsAllower
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 178
diff changeset
85 PythonThreadsAllower allower;
f34f3a149c22 added class PythonThreadsAllower
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 178
diff changeset
86 OrthancPluginCompressAndAnswerPngImage(OrthancPlugins::GetGlobalContext(), self->object_, static_cast<OrthancPluginPixelFormat>(arg0), arg1, arg2, arg3, arg4.buf);
f34f3a149c22 added class PythonThreadsAllower
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 178
diff changeset
87 }
129
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
88 PyBuffer_Release(&arg4);
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
89
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
90 Py_INCREF(Py_None);
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
91 return Py_None;
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
92 }
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
93
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
94 static PyObject *sdk_OrthancPluginRestOutput_OrthancPluginRedirect(
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
95 sdk_OrthancPluginRestOutput_Object* self, PyObject *args)
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
96 {
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
97 PythonLock::LogCall("Calling method OrthancPluginRedirect() on object of class OrthancPluginRestOutput");
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
98
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
99 if (self->object_ == NULL)
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
100 {
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
101 PyErr_SetString(PyExc_ValueError, "Invalid object");
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
102 return NULL;
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
103 }
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
104
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
105 const char* arg0 = NULL;
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
106
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
107 if (!PyArg_ParseTuple(args, "s", &arg0))
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
108 {
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
109 PyErr_SetString(PyExc_TypeError, "Bad types for the arguments (1 arguments expected)");
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
110 return NULL;
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
111 }
174
e9be3c9294d4 [IMPORTANT] replaced old auto-generated code with Java code model
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 149
diff changeset
112
184
f34f3a149c22 added class PythonThreadsAllower
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 178
diff changeset
113 {
f34f3a149c22 added class PythonThreadsAllower
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 178
diff changeset
114 PythonThreadsAllower allower;
f34f3a149c22 added class PythonThreadsAllower
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 178
diff changeset
115 OrthancPluginRedirect(OrthancPlugins::GetGlobalContext(), self->object_, arg0);
f34f3a149c22 added class PythonThreadsAllower
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 178
diff changeset
116 }
129
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
117
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
118
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
119 Py_INCREF(Py_None);
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
120 return Py_None;
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
121 }
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
122
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
123 static PyObject *sdk_OrthancPluginRestOutput_OrthancPluginSendHttpStatusCode(
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
124 sdk_OrthancPluginRestOutput_Object* self, PyObject *args)
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
125 {
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
126 PythonLock::LogCall("Calling method OrthancPluginSendHttpStatusCode() on object of class OrthancPluginRestOutput");
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
127
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
128 if (self->object_ == NULL)
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
129 {
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
130 PyErr_SetString(PyExc_ValueError, "Invalid object");
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
131 return NULL;
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
132 }
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
133
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
134 unsigned short arg0 = 0;
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
135
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
136 if (!PyArg_ParseTuple(args, "H", &arg0))
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
137 {
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
138 PyErr_SetString(PyExc_TypeError, "Bad types for the arguments (1 arguments expected)");
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
139 return NULL;
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
140 }
174
e9be3c9294d4 [IMPORTANT] replaced old auto-generated code with Java code model
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 149
diff changeset
141
184
f34f3a149c22 added class PythonThreadsAllower
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 178
diff changeset
142 {
f34f3a149c22 added class PythonThreadsAllower
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 178
diff changeset
143 PythonThreadsAllower allower;
f34f3a149c22 added class PythonThreadsAllower
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 178
diff changeset
144 OrthancPluginSendHttpStatusCode(OrthancPlugins::GetGlobalContext(), self->object_, arg0);
f34f3a149c22 added class PythonThreadsAllower
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 178
diff changeset
145 }
129
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
146
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
147
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
148 Py_INCREF(Py_None);
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
149 return Py_None;
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
150 }
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
151
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
152 static PyObject *sdk_OrthancPluginRestOutput_OrthancPluginSendUnauthorized(
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
153 sdk_OrthancPluginRestOutput_Object* self, PyObject *args)
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
154 {
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
155 PythonLock::LogCall("Calling method OrthancPluginSendUnauthorized() on object of class OrthancPluginRestOutput");
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
156
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
157 if (self->object_ == NULL)
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
158 {
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
159 PyErr_SetString(PyExc_ValueError, "Invalid object");
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
160 return NULL;
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
161 }
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
162
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
163 const char* arg0 = NULL;
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
164
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
165 if (!PyArg_ParseTuple(args, "s", &arg0))
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
166 {
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
167 PyErr_SetString(PyExc_TypeError, "Bad types for the arguments (1 arguments expected)");
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
168 return NULL;
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
169 }
174
e9be3c9294d4 [IMPORTANT] replaced old auto-generated code with Java code model
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 149
diff changeset
170
184
f34f3a149c22 added class PythonThreadsAllower
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 178
diff changeset
171 {
f34f3a149c22 added class PythonThreadsAllower
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 178
diff changeset
172 PythonThreadsAllower allower;
f34f3a149c22 added class PythonThreadsAllower
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 178
diff changeset
173 OrthancPluginSendUnauthorized(OrthancPlugins::GetGlobalContext(), self->object_, arg0);
f34f3a149c22 added class PythonThreadsAllower
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 178
diff changeset
174 }
129
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
175
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
176
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
177 Py_INCREF(Py_None);
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
178 return Py_None;
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
179 }
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
180
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
181 static PyObject *sdk_OrthancPluginRestOutput_OrthancPluginSendMethodNotAllowed(
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
182 sdk_OrthancPluginRestOutput_Object* self, PyObject *args)
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
183 {
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
184 PythonLock::LogCall("Calling method OrthancPluginSendMethodNotAllowed() on object of class OrthancPluginRestOutput");
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
185
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
186 if (self->object_ == NULL)
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
187 {
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
188 PyErr_SetString(PyExc_ValueError, "Invalid object");
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
189 return NULL;
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
190 }
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
191
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
192 const char* arg0 = NULL;
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
193
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
194 if (!PyArg_ParseTuple(args, "s", &arg0))
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
195 {
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
196 PyErr_SetString(PyExc_TypeError, "Bad types for the arguments (1 arguments expected)");
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
197 return NULL;
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
198 }
174
e9be3c9294d4 [IMPORTANT] replaced old auto-generated code with Java code model
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 149
diff changeset
199
184
f34f3a149c22 added class PythonThreadsAllower
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 178
diff changeset
200 {
f34f3a149c22 added class PythonThreadsAllower
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 178
diff changeset
201 PythonThreadsAllower allower;
f34f3a149c22 added class PythonThreadsAllower
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 178
diff changeset
202 OrthancPluginSendMethodNotAllowed(OrthancPlugins::GetGlobalContext(), self->object_, arg0);
f34f3a149c22 added class PythonThreadsAllower
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 178
diff changeset
203 }
129
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
204
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
205
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
206 Py_INCREF(Py_None);
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
207 return Py_None;
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
208 }
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
209
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
210 static PyObject *sdk_OrthancPluginRestOutput_OrthancPluginSetCookie(
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
211 sdk_OrthancPluginRestOutput_Object* self, PyObject *args)
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
212 {
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
213 PythonLock::LogCall("Calling method OrthancPluginSetCookie() on object of class OrthancPluginRestOutput");
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
214
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
215 if (self->object_ == NULL)
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
216 {
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
217 PyErr_SetString(PyExc_ValueError, "Invalid object");
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
218 return NULL;
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
219 }
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
220
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
221 const char* arg0 = NULL;
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
222 const char* arg1 = NULL;
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
223
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
224 if (!PyArg_ParseTuple(args, "ss", &arg0, &arg1))
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
225 {
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
226 PyErr_SetString(PyExc_TypeError, "Bad types for the arguments (2 arguments expected)");
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
227 return NULL;
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
228 }
174
e9be3c9294d4 [IMPORTANT] replaced old auto-generated code with Java code model
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 149
diff changeset
229
184
f34f3a149c22 added class PythonThreadsAllower
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 178
diff changeset
230 {
f34f3a149c22 added class PythonThreadsAllower
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 178
diff changeset
231 PythonThreadsAllower allower;
f34f3a149c22 added class PythonThreadsAllower
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 178
diff changeset
232 OrthancPluginSetCookie(OrthancPlugins::GetGlobalContext(), self->object_, arg0, arg1);
f34f3a149c22 added class PythonThreadsAllower
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 178
diff changeset
233 }
129
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
234
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
235
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
236 Py_INCREF(Py_None);
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
237 return Py_None;
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
238 }
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
239
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
240 static PyObject *sdk_OrthancPluginRestOutput_OrthancPluginSetHttpHeader(
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
241 sdk_OrthancPluginRestOutput_Object* self, PyObject *args)
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
242 {
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
243 PythonLock::LogCall("Calling method OrthancPluginSetHttpHeader() on object of class OrthancPluginRestOutput");
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
244
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
245 if (self->object_ == NULL)
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
246 {
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
247 PyErr_SetString(PyExc_ValueError, "Invalid object");
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
248 return NULL;
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
249 }
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
250
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
251 const char* arg0 = NULL;
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
252 const char* arg1 = NULL;
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
253
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
254 if (!PyArg_ParseTuple(args, "ss", &arg0, &arg1))
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
255 {
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
256 PyErr_SetString(PyExc_TypeError, "Bad types for the arguments (2 arguments expected)");
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
257 return NULL;
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
258 }
174
e9be3c9294d4 [IMPORTANT] replaced old auto-generated code with Java code model
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 149
diff changeset
259
184
f34f3a149c22 added class PythonThreadsAllower
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 178
diff changeset
260 {
f34f3a149c22 added class PythonThreadsAllower
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 178
diff changeset
261 PythonThreadsAllower allower;
f34f3a149c22 added class PythonThreadsAllower
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 178
diff changeset
262 OrthancPluginSetHttpHeader(OrthancPlugins::GetGlobalContext(), self->object_, arg0, arg1);
f34f3a149c22 added class PythonThreadsAllower
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 178
diff changeset
263 }
129
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
264
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
265
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
266 Py_INCREF(Py_None);
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
267 return Py_None;
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
268 }
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
269
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
270 static PyObject *sdk_OrthancPluginRestOutput_OrthancPluginStartMultipartAnswer(
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
271 sdk_OrthancPluginRestOutput_Object* self, PyObject *args)
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
272 {
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
273 PythonLock::LogCall("Calling method OrthancPluginStartMultipartAnswer() on object of class OrthancPluginRestOutput");
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
274
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
275 if (self->object_ == NULL)
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
276 {
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
277 PyErr_SetString(PyExc_ValueError, "Invalid object");
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
278 return NULL;
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
279 }
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
280
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
281 const char* arg0 = NULL;
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
282 const char* arg1 = NULL;
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
283
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
284 if (!PyArg_ParseTuple(args, "ss", &arg0, &arg1))
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
285 {
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
286 PyErr_SetString(PyExc_TypeError, "Bad types for the arguments (2 arguments expected)");
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
287 return NULL;
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
288 }
174
e9be3c9294d4 [IMPORTANT] replaced old auto-generated code with Java code model
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 149
diff changeset
289
184
f34f3a149c22 added class PythonThreadsAllower
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 178
diff changeset
290 OrthancPluginErrorCode code;
f34f3a149c22 added class PythonThreadsAllower
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 178
diff changeset
291 {
f34f3a149c22 added class PythonThreadsAllower
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 178
diff changeset
292 PythonThreadsAllower allower;
f34f3a149c22 added class PythonThreadsAllower
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 178
diff changeset
293 code = OrthancPluginStartMultipartAnswer(OrthancPlugins::GetGlobalContext(), self->object_, arg0, arg1);
f34f3a149c22 added class PythonThreadsAllower
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 178
diff changeset
294 }
129
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
295
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
296
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
297 if (code == OrthancPluginErrorCode_Success)
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
298 {
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
299 Py_INCREF(Py_None);
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
300 return Py_None;
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
301 }
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
302 else
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
303 {
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
304 PythonLock::RaiseException(code);
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
305 return NULL;
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
306 }
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
307 }
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
308
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
309 static PyObject *sdk_OrthancPluginRestOutput_OrthancPluginSendMultipartItem(
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
310 sdk_OrthancPluginRestOutput_Object* self, PyObject *args)
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
311 {
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
312 PythonLock::LogCall("Calling method OrthancPluginSendMultipartItem() on object of class OrthancPluginRestOutput");
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
313
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
314 if (self->object_ == NULL)
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
315 {
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
316 PyErr_SetString(PyExc_ValueError, "Invalid object");
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
317 return NULL;
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
318 }
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
319
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
320 Py_buffer arg0;
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
321
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
322 if (!PyArg_ParseTuple(args, "s*", &arg0))
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
323 {
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
324 PyErr_SetString(PyExc_TypeError, "Bad types for the arguments (1 arguments expected)");
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
325 return NULL;
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
326 }
174
e9be3c9294d4 [IMPORTANT] replaced old auto-generated code with Java code model
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 149
diff changeset
327
184
f34f3a149c22 added class PythonThreadsAllower
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 178
diff changeset
328 OrthancPluginErrorCode code;
f34f3a149c22 added class PythonThreadsAllower
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 178
diff changeset
329 {
f34f3a149c22 added class PythonThreadsAllower
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 178
diff changeset
330 PythonThreadsAllower allower;
f34f3a149c22 added class PythonThreadsAllower
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 178
diff changeset
331 code = OrthancPluginSendMultipartItem(OrthancPlugins::GetGlobalContext(), self->object_, arg0.buf, arg0.len);
f34f3a149c22 added class PythonThreadsAllower
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 178
diff changeset
332 }
129
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
333 PyBuffer_Release(&arg0);
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
334
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
335 if (code == OrthancPluginErrorCode_Success)
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
336 {
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
337 Py_INCREF(Py_None);
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
338 return Py_None;
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
339 }
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
340 else
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
341 {
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
342 PythonLock::RaiseException(code);
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
343 return NULL;
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
344 }
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
345 }
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
346
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
347 static PyObject *sdk_OrthancPluginRestOutput_OrthancPluginSendHttpStatus(
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
348 sdk_OrthancPluginRestOutput_Object* self, PyObject *args)
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
349 {
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
350 PythonLock::LogCall("Calling method OrthancPluginSendHttpStatus() on object of class OrthancPluginRestOutput");
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
351
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
352 if (self->object_ == NULL)
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
353 {
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
354 PyErr_SetString(PyExc_ValueError, "Invalid object");
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
355 return NULL;
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
356 }
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
357
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
358 unsigned short arg0 = 0;
177
008be55355a4 regenerating the wrapper after patching SDK
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 149
diff changeset
359 Py_buffer arg1;
129
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
360
177
008be55355a4 regenerating the wrapper after patching SDK
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 149
diff changeset
361 if (!PyArg_ParseTuple(args, "Hs*", &arg0, &arg1))
129
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
362 {
177
008be55355a4 regenerating the wrapper after patching SDK
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 149
diff changeset
363 PyErr_SetString(PyExc_TypeError, "Bad types for the arguments (2 arguments expected)");
129
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
364 return NULL;
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
365 }
174
e9be3c9294d4 [IMPORTANT] replaced old auto-generated code with Java code model
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 149
diff changeset
366
184
f34f3a149c22 added class PythonThreadsAllower
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 178
diff changeset
367 {
f34f3a149c22 added class PythonThreadsAllower
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 178
diff changeset
368 PythonThreadsAllower allower;
f34f3a149c22 added class PythonThreadsAllower
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 178
diff changeset
369 OrthancPluginSendHttpStatus(OrthancPlugins::GetGlobalContext(), self->object_, arg0, arg1.buf, arg1.len);
f34f3a149c22 added class PythonThreadsAllower
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 178
diff changeset
370 }
177
008be55355a4 regenerating the wrapper after patching SDK
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 149
diff changeset
371 PyBuffer_Release(&arg1);
129
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
372
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
373 Py_INCREF(Py_None);
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
374 return Py_None;
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
375 }
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
376
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
377 static PyObject *sdk_OrthancPluginRestOutput_OrthancPluginCompressAndAnswerJpegImage(
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
378 sdk_OrthancPluginRestOutput_Object* self, PyObject *args)
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
379 {
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
380 PythonLock::LogCall("Calling method OrthancPluginCompressAndAnswerJpegImage() on object of class OrthancPluginRestOutput");
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
381
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
382 if (self->object_ == NULL)
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
383 {
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
384 PyErr_SetString(PyExc_ValueError, "Invalid object");
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
385 return NULL;
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
386 }
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
387
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
388 long int arg0 = 0;
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
389 unsigned long arg1 = 0;
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
390 unsigned long arg2 = 0;
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
391 unsigned long arg3 = 0;
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
392 Py_buffer arg4;
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
393 unsigned char arg5 = 0;
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
394
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
395 if (!PyArg_ParseTuple(args, "lkkks*b", &arg0, &arg1, &arg2, &arg3, &arg4, &arg5))
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
396 {
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
397 PyErr_SetString(PyExc_TypeError, "Bad types for the arguments (6 arguments expected)");
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
398 return NULL;
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
399 }
174
e9be3c9294d4 [IMPORTANT] replaced old auto-generated code with Java code model
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 149
diff changeset
400
184
f34f3a149c22 added class PythonThreadsAllower
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 178
diff changeset
401 {
f34f3a149c22 added class PythonThreadsAllower
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 178
diff changeset
402 PythonThreadsAllower allower;
f34f3a149c22 added class PythonThreadsAllower
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 178
diff changeset
403 OrthancPluginCompressAndAnswerJpegImage(OrthancPlugins::GetGlobalContext(), self->object_, static_cast<OrthancPluginPixelFormat>(arg0), arg1, arg2, arg3, arg4.buf, arg5);
f34f3a149c22 added class PythonThreadsAllower
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 178
diff changeset
404 }
129
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
405 PyBuffer_Release(&arg4);
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
406
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
407 Py_INCREF(Py_None);
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
408 return Py_None;
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
409 }
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
410
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
411 static PyObject *sdk_OrthancPluginRestOutput_OrthancPluginSetHttpErrorDetails(
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
412 sdk_OrthancPluginRestOutput_Object* self, PyObject *args)
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
413 {
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
414 PythonLock::LogCall("Calling method OrthancPluginSetHttpErrorDetails() on object of class OrthancPluginRestOutput");
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
415
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
416 if (self->object_ == NULL)
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
417 {
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
418 PyErr_SetString(PyExc_ValueError, "Invalid object");
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
419 return NULL;
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
420 }
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
421
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
422 const char* arg0 = NULL;
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
423 unsigned char arg1 = 0;
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
424
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
425 if (!PyArg_ParseTuple(args, "sb", &arg0, &arg1))
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
426 {
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
427 PyErr_SetString(PyExc_TypeError, "Bad types for the arguments (2 arguments expected)");
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
428 return NULL;
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
429 }
174
e9be3c9294d4 [IMPORTANT] replaced old auto-generated code with Java code model
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 149
diff changeset
430
184
f34f3a149c22 added class PythonThreadsAllower
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 178
diff changeset
431 {
f34f3a149c22 added class PythonThreadsAllower
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 178
diff changeset
432 PythonThreadsAllower allower;
f34f3a149c22 added class PythonThreadsAllower
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 178
diff changeset
433 OrthancPluginSetHttpErrorDetails(OrthancPlugins::GetGlobalContext(), self->object_, arg0, arg1);
f34f3a149c22 added class PythonThreadsAllower
Sebastien Jodogne <s.jodogne@gmail.com>
parents: 178
diff changeset
434 }
129
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
435
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
436
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
437 Py_INCREF(Py_None);
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
438 return Py_None;
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
439 }
5643e97d9367 reproducible code generation
Sebastien Jodogne <s.jodogne@gmail.com>
parents:
diff changeset
440