Skip to content

Commit 144089f

Browse files
SP-18211 - add result_type discriminator
1 parent 9a4c86c commit 144089f

File tree

1 file changed

+97
-16
lines changed

1 file changed

+97
-16
lines changed

rt.yml

Lines changed: 97 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -127,6 +127,39 @@ components:
127127
type: integer
128128
result_type:
129129
$ref: "#/components/schemas/ContainerType"
130+
discriminator:
131+
propertyName: result_type
132+
mapping:
133+
33: "StatusResult"
134+
36: "TextResult"
135+
1: "DocumentImageResult"
136+
16: "DocumentImageResult"
137+
37: "ImagesResult"
138+
9: "ChosenDocumentTypeResult"
139+
8: "DocumentTypesCandidatesResult"
140+
17: "TextDataResult"
141+
3: "TextDataResult"
142+
18: "TextDataResult"
143+
26: "TextDataResult"
144+
102: "TextDataResult"
145+
6: "GraphicsResult"
146+
19: "GraphicsResult"
147+
32: "GraphicsResult"
148+
35: "GraphicsResult"
149+
38: "GraphicsResult"
150+
103: "GraphicsResult"
151+
15: "LexicalAnalysisResult"
152+
20: "AuthenticityResult"
153+
39: "AuthenticityResult"
154+
34: "AuthenticityResult"
155+
30: "ImageQualityResult"
156+
85: "DocumentPositionResult"
157+
61: "DocumentPositionResult"
158+
62: "DocumentPositionResult"
159+
5: "DocBarCodeInfo"
160+
50: "LicenseResult"
161+
49: "EncryptedRCLResult"
162+
104: "DocumentBinaryInfoResult"
130163

131164
ContainerList:
132165
title: "ContainerList"
@@ -143,19 +176,67 @@ components:
143176
type: array
144177
items:
145178
anyOf:
146-
- $ref: "./rt-status.yml#/components/schemas/StatusResult"
147-
- $ref: "./rt-text.yml#/components/schemas/TextResult"
148-
- $ref: "./rt-raw-image.yml#/components/schemas/DocumentImageResult"
149-
- $ref: "./rt-images.yml#/components/schemas/ImagesResult"
150-
- $ref: "./rt-doc-type-old.yml#/components/schemas/ChosenDocumentTypeResult"
151-
- $ref: "./rt-doc-type-old.yml#/components/schemas/DocumentTypesCandidatesResult"
152-
- $ref: "./rt-text-data.yml#/components/schemas/TextDataResult"
153-
- $ref: "./rt-image-data.yml#/components/schemas/GraphicsResult"
154-
- $ref: "./rt-ocr-lexical-analysis.yml#/components/schemas/LexicalAnalysisResult"
155-
- $ref: "./rt-authenticity.yml#/components/schemas/AuthenticityResult"
156-
- $ref: "./rt-image-quality.yml#/components/schemas/ImageQualityResult"
157-
- $ref: "./rt-document-position.yml#/components/schemas/DocumentPositionResult"
158-
- $ref: "./rt-barcodes.yml#/components/schemas/DocBarCodeInfo"
159-
- $ref: "./rt-license.yml#/components/schemas/LicenseResult"
160-
- $ref: "./rt-encrypted-rcl.yml#/components/schemas/EncryptedRCLResult"
161-
- $ref: "./rt-rfid-binary-data.yml#/components/schemas/DocumentBinaryInfoResult"
179+
- $ref: "#/components/schemas/StatusResult"
180+
- $ref: "#/components/schemas/TextResult"
181+
- $ref: "#/components/schemas/DocumentImageResult"
182+
- $ref: "#/components/schemas/ImagesResult"
183+
- $ref: "#/components/schemas/ChosenDocumentTypeResult"
184+
- $ref: "#/components/schemas/DocumentTypesCandidatesResult"
185+
- $ref: "#/components/schemas/TextDataResult"
186+
- $ref: "#/components/schemas/GraphicsResult"
187+
- $ref: "#/components/schemas/LexicalAnalysisResult"
188+
- $ref: "#/components/schemas/AuthenticityResult"
189+
- $ref: "#/components/schemas/ImageQualityResult"
190+
- $ref: "#/components/schemas/DocumentPositionResult"
191+
- $ref: "#/components/schemas/DocBarCodeInfo"
192+
- $ref: "#/components/schemas/LicenseResult"
193+
- $ref: "#/components/schemas/EncryptedRCLResult"
194+
- $ref: "#/components/schemas/DocumentBinaryInfoResult"
195+
196+
StatusResult:
197+
$ref: "./rt-status.yml#/components/schemas/StatusResult"
198+
199+
TextResult:
200+
$ref: "./rt-text.yml#/components/schemas/TextResult"
201+
202+
DocumentImageResult:
203+
$ref: "./rt-raw-image.yml#/components/schemas/DocumentImageResult"
204+
205+
ImagesResult:
206+
$ref: "./rt-images.yml#/components/schemas/ImagesResult"
207+
208+
ChosenDocumentTypeResult:
209+
$ref: "./rt-doc-type-old.yml#/components/schemas/ChosenDocumentTypeResult"
210+
211+
DocumentTypesCandidatesResult:
212+
$ref: "./rt-doc-type-old.yml#/components/schemas/DocumentTypesCandidatesResult"
213+
214+
TextDataResult:
215+
$ref: "./rt-text-data.yml#/components/schemas/TextDataResult"
216+
217+
GraphicsResult:
218+
$ref: "./rt-image-data.yml#/components/schemas/GraphicsResult"
219+
220+
LexicalAnalysisResult:
221+
$ref: "./rt-ocr-lexical-analysis.yml#/components/schemas/LexicalAnalysisResult"
222+
223+
AuthenticityResult:
224+
$ref: "./rt-authenticity.yml#/components/schemas/AuthenticityResult"
225+
226+
ImageQualityResult:
227+
$ref: "./rt-image-quality.yml#/components/schemas/ImageQualityResult"
228+
229+
DocumentPositionResult:
230+
$ref: "./rt-document-position.yml#/components/schemas/DocumentPositionResult"
231+
232+
DocBarCodeInfo:
233+
$ref: "./rt-barcodes.yml#/components/schemas/DocBarCodeInfo"
234+
235+
LicenseResult:
236+
$ref: "./rt-license.yml#/components/schemas/LicenseResult"
237+
238+
EncryptedRCLResult:
239+
$ref: "./rt-encrypted-rcl.yml#/components/schemas/EncryptedRCLResult"
240+
241+
DocumentBinaryInfoResult:
242+
$ref: "./rt-rfid-binary-data.yml#/components/schemas/DocumentBinaryInfoResult"

0 commit comments

Comments
 (0)