YAZ  5.23.1
z-core.c
Go to the documentation of this file.
1 
6 #if HAVE_CONFIG_H
7 #include <config.h>
8 #endif
9 
10 #include <yaz/z-core.h>
11 
12 int z_APDU(ODR o, Z_APDU **p, int opt, const char *name)
13 {
14  static Odr_arm arm[] = {
16  (Odr_fun) z_InitRequest, "initRequest"},
18  (Odr_fun) z_InitResponse, "initResponse"},
20  (Odr_fun) z_SearchRequest, "searchRequest"},
22  (Odr_fun) z_SearchResponse, "searchResponse"},
24  (Odr_fun) z_PresentRequest, "presentRequest"},
26  (Odr_fun) z_PresentResponse, "presentResponse"},
28  (Odr_fun) z_DeleteResultSetRequest, "deleteResultSetRequest"},
30  (Odr_fun) z_DeleteResultSetResponse, "deleteResultSetResponse"},
32  (Odr_fun) z_AccessControlRequest, "accessControlRequest"},
34  (Odr_fun) z_AccessControlResponse, "accessControlResponse"},
36  (Odr_fun) z_ResourceControlRequest, "resourceControlRequest"},
38  (Odr_fun) z_ResourceControlResponse, "resourceControlResponse"},
40  (Odr_fun) z_TriggerResourceControlRequest, "triggerResourceControlRequest"},
42  (Odr_fun) z_ResourceReportRequest, "resourceReportRequest"},
44  (Odr_fun) z_ResourceReportResponse, "resourceReportResponse"},
46  (Odr_fun) z_ScanRequest, "scanRequest"},
48  (Odr_fun) z_ScanResponse, "scanResponse"},
50  (Odr_fun) z_SortRequest, "sortRequest"},
52  (Odr_fun) z_SortResponse, "sortResponse"},
54  (Odr_fun) z_Segment, "segmentRequest"},
56  (Odr_fun) z_ExtendedServicesRequest, "extendedServicesRequest"},
58  (Odr_fun) z_ExtendedServicesResponse, "extendedServicesResponse"},
60  (Odr_fun) z_Close, "close"},
62  (Odr_fun) z_DuplicateDetectionRequest, "duplicateDetectionRequest"},
64  (Odr_fun) z_DuplicateDetectionResponse, "duplicateDetectionResponse"},
65  {-1, -1, -1, -1, (Odr_fun) 0, 0}
66  };
67  if (!odr_initmember(o, p, sizeof(**p)))
68  return odr_missing(o, opt, name);
69  if (odr_choice(o, arm, &(*p)->u, &(*p)->which, name))
70  return 1;
71  if (o->direction == ODR_DECODE)
72  *p = 0;
73  return odr_missing(o, opt, name);
74 }
75 
76 int z_InitRequest(ODR o, Z_InitRequest **p, int opt, const char *name)
77 {
78  if (!odr_sequence_begin(o, p, sizeof(**p), name))
79  return odr_missing(o, opt, name) && odr_ok (o);
80  return
81  z_ReferenceId(o, &(*p)->referenceId, 1, "referenceId") &&
82  z_ProtocolVersion(o, &(*p)->protocolVersion, 0, "protocolVersion") &&
83  z_Options(o, &(*p)->options, 0, "options") &&
85  &(*p)->preferredMessageSize, ODR_CONTEXT, 5, 0, "preferredMessageSize") &&
87  &(*p)->maximumRecordSize, ODR_CONTEXT, 6, 0, "maximumRecordSize") &&
89  &(*p)->idAuthentication, ODR_CONTEXT, 7, 1, "idAuthentication") &&
91  &(*p)->implementationId, ODR_CONTEXT, 110, 1, "implementationId") &&
93  &(*p)->implementationName, ODR_CONTEXT, 111, 1, "implementationName") &&
95  &(*p)->implementationVersion, ODR_CONTEXT, 112, 1, "implementationVersion") &&
97  &(*p)->userInformationField, ODR_CONTEXT, 11, 1, "userInformationField") &&
98  z_OtherInformation(o, &(*p)->otherInfo, 1, "otherInfo") &&
100 }
101 
102 int z_IdPass(ODR o, Z_IdPass **p, int opt, const char *name)
103 {
104  if (!odr_sequence_begin(o, p, sizeof(**p), name))
105  return odr_missing(o, opt, name) && odr_ok (o);
106  return
108  &(*p)->groupId, ODR_CONTEXT, 0, 1, "groupId") &&
110  &(*p)->userId, ODR_CONTEXT, 1, 1, "userId") &&
112  &(*p)->password, ODR_CONTEXT, 2, 1, "password") &&
113  odr_sequence_end(o);
114 }
115 
116 int z_IdAuthentication(ODR o, Z_IdAuthentication **p, int opt, const char *name)
117 {
118  static Odr_arm arm[] = {
119  {-1, -1, -1, Z_IdAuthentication_open,
120  (Odr_fun) odr_visiblestring, "open"},
121  {-1, -1, -1, Z_IdAuthentication_idPass,
122  (Odr_fun) z_IdPass, "idPass"},
123  {-1, -1, -1, Z_IdAuthentication_anonymous,
124  (Odr_fun) odr_null, "anonymous"},
125  {-1, -1, -1, Z_IdAuthentication_other,
126  (Odr_fun) z_External, "other"},
127  {-1, -1, -1, -1, (Odr_fun) 0, 0}
128  };
129  if (!odr_initmember(o, p, sizeof(**p)))
130  return odr_missing(o, opt, name);
131  if (odr_choice(o, arm, &(*p)->u, &(*p)->which, name))
132  return 1;
133  if (o->direction == ODR_DECODE)
134  *p = 0;
135  return odr_missing(o, opt, name);
136 }
137 
138 int z_InitResponse(ODR o, Z_InitResponse **p, int opt, const char *name)
139 {
140  if (!odr_sequence_begin(o, p, sizeof(**p), name))
141  return odr_missing(o, opt, name) && odr_ok (o);
142  return
143  z_ReferenceId(o, &(*p)->referenceId, 1, "referenceId") &&
144  z_ProtocolVersion(o, &(*p)->protocolVersion, 0, "protocolVersion") &&
145  z_Options(o, &(*p)->options, 0, "options") &&
147  &(*p)->preferredMessageSize, ODR_CONTEXT, 5, 0, "preferredMessageSize") &&
149  &(*p)->maximumRecordSize, ODR_CONTEXT, 6, 0, "maximumRecordSize") &&
151  &(*p)->result, ODR_CONTEXT, 12, 0, "result") &&
153  &(*p)->implementationId, ODR_CONTEXT, 110, 1, "implementationId") &&
155  &(*p)->implementationName, ODR_CONTEXT, 111, 1, "implementationName") &&
157  &(*p)->implementationVersion, ODR_CONTEXT, 112, 1, "implementationVersion") &&
159  &(*p)->userInformationField, ODR_CONTEXT, 11, 1, "userInformationField") &&
160  z_OtherInformation(o, &(*p)->otherInfo, 1, "otherInfo") &&
161  odr_sequence_end(o);
162 }
163 
164 int z_ProtocolVersion(ODR o, Z_ProtocolVersion **p, int opt, const char *name)
165 {
166  return odr_implicit_tag(o, odr_bitstring, p, ODR_CONTEXT, 3, opt, name);
167 }
168 
169 int z_Options(ODR o, Z_Options **p, int opt, const char *name)
170 {
171  return odr_implicit_tag(o, odr_bitstring, p, ODR_CONTEXT, 4, opt, name);
172 }
173 
174 int z_SearchRequest(ODR o, Z_SearchRequest **p, int opt, const char *name)
175 {
176  if (!odr_sequence_begin(o, p, sizeof(**p), name))
177  return odr_missing(o, opt, name) && odr_ok (o);
178  return
179  z_ReferenceId(o, &(*p)->referenceId, 1, "referenceId") &&
181  &(*p)->smallSetUpperBound, ODR_CONTEXT, 13, 0, "smallSetUpperBound") &&
183  &(*p)->largeSetLowerBound, ODR_CONTEXT, 14, 0, "largeSetLowerBound") &&
185  &(*p)->mediumSetPresentNumber, ODR_CONTEXT, 15, 0, "mediumSetPresentNumber") &&
187  &(*p)->replaceIndicator, ODR_CONTEXT, 16, 0, "replaceIndicator") &&
189  &(*p)->resultSetName, ODR_CONTEXT, 17, 0, "resultSetName") &&
191  odr_sequence_of(o, (Odr_fun) z_DatabaseName, &(*p)->databaseNames,
192  &(*p)->num_databaseNames, "databaseNames") &&
194  &(*p)->smallSetElementSetNames, ODR_CONTEXT, 100, 1, "smallSetElementSetNames") &&
196  &(*p)->mediumSetElementSetNames, ODR_CONTEXT, 101, 1, "mediumSetElementSetNames") &&
198  &(*p)->preferredRecordSyntax, ODR_CONTEXT, 104, 1, "preferredRecordSyntax") &&
200  &(*p)->query, ODR_CONTEXT, 21, 0, "query") &&
202  &(*p)->additionalSearchInfo, ODR_CONTEXT, 203, 1, "additionalSearchInfo") &&
203  z_OtherInformation(o, &(*p)->otherInfo, 1, "otherInfo") &&
204  odr_sequence_end(o);
205 }
206 
207 int z_Query(ODR o, Z_Query **p, int opt, const char *name)
208 {
209  static Odr_arm arm[] = {
211  (Odr_fun) z_ANY_type_0, "type_0"},
213  (Odr_fun) z_RPNQuery, "type_1"},
215  (Odr_fun) odr_octetstring, "type_2"},
217  (Odr_fun) odr_octetstring, "type_100"},
219  (Odr_fun) z_RPNQuery, "type_101"},
221  (Odr_fun) odr_octetstring, "type_102"},
223  (Odr_fun) z_External, "type_104"},
224  {-1, -1, -1, -1, (Odr_fun) 0, 0}
225  };
226  if (!odr_initmember(o, p, sizeof(**p)))
227  return odr_missing(o, opt, name);
228  if (odr_choice(o, arm, &(*p)->u, &(*p)->which, name))
229  return 1;
230  if (o->direction == ODR_DECODE)
231  *p = 0;
232  return odr_missing(o, opt, name);
233 }
234 
235 int z_RPNQuery(ODR o, Z_RPNQuery **p, int opt, const char *name)
236 {
237  if (!odr_sequence_begin(o, p, sizeof(**p), name))
238  return odr_missing(o, opt, name) && odr_ok (o);
239  return
240  z_AttributeSetId(o, &(*p)->attributeSetId, 0, "attributeSetId") &&
241  z_RPNStructure(o, &(*p)->RPNStructure, 0, "RPNStructure") &&
242  odr_sequence_end(o);
243 }
244 
245 int z_Complex(ODR o, Z_Complex **p, int opt, const char *name)
246 {
247  if (!odr_sequence_begin(o, p, sizeof(**p), name))
248  return odr_missing(o, opt, name) && odr_ok (o);
249  return
250  z_RPNStructure(o, &(*p)->s1, 0, "s1") &&
251  z_RPNStructure(o, &(*p)->s2, 0, "s2") &&
252  z_Operator(o, &(*p)->roperator, 0, "roperator") &&
253  odr_sequence_end(o);
254 }
255 
256 int z_RPNStructure(ODR o, Z_RPNStructure **p, int opt, const char *name)
257 {
258  static Odr_arm arm[] = {
260  (Odr_fun) z_Operand, "simple"},
262  (Odr_fun) z_Complex, "complex"},
263  {-1, -1, -1, -1, (Odr_fun) 0, 0}
264  };
265  if (!odr_initmember(o, p, sizeof(**p)))
266  return odr_missing(o, opt, name);
267  if (odr_choice(o, arm, &(*p)->u, &(*p)->which, name))
268  return 1;
269  if (o->direction == ODR_DECODE)
270  *p = 0;
271  return odr_missing(o, opt, name);
272 }
273 
274 int z_Operand(ODR o, Z_Operand **p, int opt, const char *name)
275 {
276  static Odr_arm arm[] = {
277  {-1, -1, -1, Z_Operand_APT,
278  (Odr_fun) z_AttributesPlusTerm, "attributesPlusTerm"},
279  {-1, -1, -1, Z_Operand_resultSetId,
280  (Odr_fun) z_ResultSetId, "resultSetId"},
281  {-1, -1, -1, Z_Operand_resultAttr,
282  (Odr_fun) z_ResultSetPlusAttributes, "resultAttr"},
283  {-1, -1, -1, -1, (Odr_fun) 0, 0}
284  };
285  if (!odr_initmember(o, p, sizeof(**p)))
286  return odr_missing(o, opt, name);
287  if (odr_choice(o, arm, &(*p)->u, &(*p)->which, name))
288  return 1;
289  if (o->direction == ODR_DECODE)
290  *p = 0;
291  return odr_missing(o, opt, name);
292 }
293 
294 int z_AttributesPlusTerm(ODR o, Z_AttributesPlusTerm **p, int opt, const char *name)
295 {
296  if (!odr_implicit_settag(o, ODR_CONTEXT, 102) ||
297  !odr_sequence_begin (o, p, sizeof(**p), name))
298  return odr_missing(o, opt, name);
299  return
300  z_AttributeList(o, &(*p)->attributes, 0, "attributes") &&
301  z_Term(o, &(*p)->term, 0, "term") &&
302  odr_sequence_end(o);
303 }
304 
306 {
307  if (!odr_implicit_settag(o, ODR_CONTEXT, 214) ||
308  !odr_sequence_begin (o, p, sizeof(**p), name))
309  return odr_missing(o, opt, name);
310  return
311  z_ResultSetId(o, &(*p)->resultSet, 0, "resultSet") &&
312  z_AttributeList(o, &(*p)->attributes, 0, "attributes") &&
313  odr_sequence_end(o);
314 }
315 
316 int z_AttributeList(ODR o, Z_AttributeList **p, int opt, const char *name)
317 {
318  if (!odr_initmember(o, p, sizeof(**p)))
319  return odr_missing(o, opt, name);
321  if (odr_sequence_of(o, (Odr_fun) z_AttributeElement, &(*p)->attributes,
322  &(*p)->num_attributes, name))
323  return 1;
324  if (o->direction == ODR_DECODE)
325  *p = 0;
326  return odr_missing(o, opt, name);
327 }
328 
329 int z_Term(ODR o, Z_Term **p, int opt, const char *name)
330 {
331  static Odr_arm arm[] = {
333  (Odr_fun) odr_octetstring, "general"},
335  (Odr_fun) odr_integer, "numeric"},
337  (Odr_fun) z_InternationalString, "characterString"},
339  (Odr_fun) odr_oid, "oid"},
341  (Odr_fun) odr_generalizedtime, "dateTime"},
343  (Odr_fun) z_External, "external"},
345  (Odr_fun) z_IntUnit, "integerAndUnit"},
347  (Odr_fun) odr_null, "null"},
348  {-1, -1, -1, -1, (Odr_fun) 0, 0}
349  };
350  if (!odr_initmember(o, p, sizeof(**p)))
351  return odr_missing(o, opt, name);
352  if (odr_choice(o, arm, &(*p)->u, &(*p)->which, name))
353  return 1;
354  if (o->direction == ODR_DECODE)
355  *p = 0;
356  return odr_missing(o, opt, name);
357 }
358 
359 int z_Operator(ODR o, Z_Operator **p, int opt, const char *name)
360 {
361  static Odr_arm arm[] = {
363  (Odr_fun) odr_null, "op_and"},
365  (Odr_fun) odr_null, "op_or"},
367  (Odr_fun) odr_null, "and_not"},
369  (Odr_fun) z_ProximityOperator, "prox"},
370  {-1, -1, -1, -1, (Odr_fun) 0, 0}
371  };
372  if (!odr_constructed_begin(o, p, ODR_CONTEXT, 46, 0))
373  return odr_missing(o, opt, name);
374  if (!odr_initmember(o, p, sizeof(**p)))
375  return odr_missing(o, opt, name);
376  if (odr_choice(o, arm, &(*p)->u, &(*p)->which, name) &&
378  return 1;
379  if (o->direction == ODR_DECODE)
380  *p = 0;
381  return odr_missing(o, opt, name);
382 }
383 
384 int z_ComplexAttribute(ODR o, Z_ComplexAttribute **p, int opt, const char *name)
385 {
386  if (!odr_sequence_begin(o, p, sizeof(**p), name))
387  return odr_missing(o, opt, name) && odr_ok (o);
388  return
390  odr_sequence_of(o, (Odr_fun) z_StringOrNumeric, &(*p)->list,
391  &(*p)->num_list, "list") &&
393  (odr_sequence_of(o, (Odr_fun) odr_integer, &(*p)->semanticAction,
394  &(*p)->num_semanticAction, "semanticAction") || odr_ok(o)) &&
395  odr_sequence_end(o);
396 }
397 
398 int z_AttributeElement(ODR o, Z_AttributeElement **p, int opt, const char *name)
399 {
400  static Odr_arm arm[] = {
402  (Odr_fun) odr_integer, "numeric"},
404  (Odr_fun) z_ComplexAttribute, "complex"},
405  {-1, -1, -1, -1, (Odr_fun) 0, 0}
406  };
407  if (!odr_sequence_begin(o, p, sizeof(**p), name))
408  return odr_missing(o, opt, name) && odr_ok (o);
409  return
411  &(*p)->attributeSet, ODR_CONTEXT, 1, 1, "attributeSet") &&
413  &(*p)->attributeType, ODR_CONTEXT, 120, 0, "attributeType") &&
414  odr_choice(o, arm, &(*p)->value, &(*p)->which, 0) &&
415  odr_sequence_end(o);
416 }
417 
418 int z_ProximityOperator(ODR o, Z_ProximityOperator **p, int opt, const char *name)
419 {
420  static Odr_arm arm[] = {
422  (Odr_fun) z_ProxUnit, "known"},
424  (Odr_fun) odr_integer, "zprivate"},
425  {-1, -1, -1, -1, (Odr_fun) 0, 0}
426  };
427  if (!odr_sequence_begin(o, p, sizeof(**p), name))
428  return odr_missing(o, opt, name) && odr_ok (o);
429  return
431  &(*p)->exclusion, ODR_CONTEXT, 1, 1, "exclusion") &&
433  &(*p)->distance, ODR_CONTEXT, 2, 0, "distance") &&
435  &(*p)->ordered, ODR_CONTEXT, 3, 0, "ordered") &&
437  &(*p)->relationType, ODR_CONTEXT, 4, 0, "relationType") &&
438  odr_constructed_begin(o, &(*p)->u, ODR_CONTEXT, 5, "proximityUnitCode") &&
439  odr_choice(o, arm, &(*p)->u, &(*p)->which, 0) &&
440  odr_constructed_end(o) &&
441  odr_sequence_end(o);
442 }
443 
444 int z_ProxUnit(ODR o, Z_ProxUnit **p, int opt, const char *name)
445 {
446  return odr_integer (o, p, opt, name);
447 }
448 
449 int z_SearchResponse(ODR o, Z_SearchResponse **p, int opt, const char *name)
450 {
451  if (!odr_sequence_begin(o, p, sizeof(**p), name))
452  return odr_missing(o, opt, name) && odr_ok (o);
453  return
454  z_ReferenceId(o, &(*p)->referenceId, 1, "referenceId") &&
456  &(*p)->resultCount, ODR_CONTEXT, 23, 0, "resultCount") &&
458  &(*p)->numberOfRecordsReturned, ODR_CONTEXT, 24, 0, "numberOfRecordsReturned") &&
460  &(*p)->nextResultSetPosition, ODR_CONTEXT, 25, 0, "nextResultSetPosition") &&
462  &(*p)->searchStatus, ODR_CONTEXT, 22, 0, "searchStatus") &&
464  &(*p)->resultSetStatus, ODR_CONTEXT, 26, 1, "resultSetStatus") &&
465  z_PresentStatus(o, &(*p)->presentStatus, 1, "presentStatus") &&
466  z_Records(o, &(*p)->records, 1, "records") &&
468  &(*p)->additionalSearchInfo, ODR_CONTEXT, 203, 1, "additionalSearchInfo") &&
469  z_OtherInformation(o, &(*p)->otherInfo, 1, "otherInfo") &&
470  odr_sequence_end(o);
471 }
472 
473 int z_RecordComposition(ODR o, Z_RecordComposition **p, int opt, const char *name)
474 {
475  static Odr_arm arm[] = {
477  (Odr_fun) z_ElementSetNames, "simple"},
479  (Odr_fun) z_CompSpec, "complex"},
480  {-1, -1, -1, -1, (Odr_fun) 0, 0}
481  };
482  if (!odr_initmember(o, p, sizeof(**p)))
483  return odr_missing(o, opt, name);
484  if (odr_choice(o, arm, &(*p)->u, &(*p)->which, name))
485  return 1;
486  if (o->direction == ODR_DECODE)
487  *p = 0;
488  return odr_missing(o, opt, name);
489 }
490 
491 int z_PresentRequest(ODR o, Z_PresentRequest **p, int opt, const char *name)
492 {
493  if (!odr_sequence_begin(o, p, sizeof(**p), name))
494  return odr_missing(o, opt, name) && odr_ok (o);
495  return
496  z_ReferenceId(o, &(*p)->referenceId, 1, "referenceId") &&
497  z_ResultSetId(o, &(*p)->resultSetId, 0, "resultSetId") &&
499  &(*p)->resultSetStartPoint, ODR_CONTEXT, 30, 0, "resultSetStartPoint") &&
501  &(*p)->numberOfRecordsRequested, ODR_CONTEXT, 29, 0, "numberOfRecordsRequested") &&
502  odr_implicit_settag(o, ODR_CONTEXT, 212) &&
503  (odr_sequence_of(o, (Odr_fun) z_Range, &(*p)->additionalRanges,
504  &(*p)->num_ranges, "additionalRanges") || odr_ok(o)) &&
505  z_RecordComposition(o, &(*p)->recordComposition, 1, "recordComposition") &&
507  &(*p)->preferredRecordSyntax, ODR_CONTEXT, 104, 1, "preferredRecordSyntax") &&
509  &(*p)->maxSegmentCount, ODR_CONTEXT, 204, 1, "maxSegmentCount") &&
511  &(*p)->maxRecordSize, ODR_CONTEXT, 206, 1, "maxRecordSize") &&
513  &(*p)->maxSegmentSize, ODR_CONTEXT, 207, 1, "maxSegmentSize") &&
514  z_OtherInformation(o, &(*p)->otherInfo, 1, "otherInfo") &&
515  odr_sequence_end(o);
516 }
517 
518 int z_Segment(ODR o, Z_Segment **p, int opt, const char *name)
519 {
520  if (!odr_sequence_begin(o, p, sizeof(**p), name))
521  return odr_missing(o, opt, name) && odr_ok (o);
522  return
523  z_ReferenceId(o, &(*p)->referenceId, 1, "referenceId") &&
525  &(*p)->numberOfRecordsReturned, ODR_CONTEXT, 24, 0, "numberOfRecordsReturned") &&
527  odr_sequence_of(o, (Odr_fun) z_NamePlusRecord, &(*p)->segmentRecords,
528  &(*p)->num_segmentRecords, "segmentRecords") &&
529  z_OtherInformation(o, &(*p)->otherInfo, 1, "otherInfo") &&
530  odr_sequence_end(o);
531 }
532 
533 int z_PresentResponse(ODR o, Z_PresentResponse **p, int opt, const char *name)
534 {
535  if (!odr_sequence_begin(o, p, sizeof(**p), name))
536  return odr_missing(o, opt, name) && odr_ok (o);
537  return
538  z_ReferenceId(o, &(*p)->referenceId, 1, "referenceId") &&
540  &(*p)->numberOfRecordsReturned, ODR_CONTEXT, 24, 0, "numberOfRecordsReturned") &&
542  &(*p)->nextResultSetPosition, ODR_CONTEXT, 25, 0, "nextResultSetPosition") &&
543  z_PresentStatus(o, &(*p)->presentStatus, 0, "presentStatus") &&
544  z_Records(o, &(*p)->records, 1, "records") &&
545  z_OtherInformation(o, &(*p)->otherInfo, 1, "otherInfo") &&
546  odr_sequence_end(o);
547 }
548 
549 int z_NamePlusRecordList(ODR o, Z_NamePlusRecordList **p, int opt, const char *name)
550 {
551  if (!odr_initmember(o, p, sizeof(**p)))
552  return odr_missing(o, opt, name);
553  if (odr_sequence_of(o, (Odr_fun) z_NamePlusRecord, &(*p)->records,
554  &(*p)->num_records, name))
555  return 1;
556  if (o->direction == ODR_DECODE)
557  *p = 0;
558  return odr_missing(o, opt, name);
559 }
560 
561 int z_DiagRecs(ODR o, Z_DiagRecs **p, int opt, const char *name)
562 {
563  if (!odr_initmember(o, p, sizeof(**p)))
564  return odr_missing(o, opt, name);
565  if (odr_sequence_of(o, (Odr_fun) z_DiagRec, &(*p)->diagRecs,
566  &(*p)->num_diagRecs, name))
567  return 1;
568  if (o->direction == ODR_DECODE)
569  *p = 0;
570  return odr_missing(o, opt, name);
571 }
572 
573 int z_Records(ODR o, Z_Records **p, int opt, const char *name)
574 {
575  static Odr_arm arm[] = {
577  (Odr_fun) z_NamePlusRecordList, "databaseOrSurDiagnostics"},
579  (Odr_fun) z_DefaultDiagFormat, "nonSurrogateDiagnostic"},
581  (Odr_fun) z_DiagRecs, "multipleNonSurDiagnostics"},
582  {-1, -1, -1, -1, (Odr_fun) 0, 0}
583  };
584  if (!odr_initmember(o, p, sizeof(**p)))
585  return odr_missing(o, opt, name);
586  if (odr_choice(o, arm, &(*p)->u, &(*p)->which, name))
587  return 1;
588  if (o->direction == ODR_DECODE)
589  *p = 0;
590  return odr_missing(o, opt, name);
591 }
592 
593 int z_NamePlusRecord(ODR o, Z_NamePlusRecord **p, int opt, const char *name)
594 {
595  static Odr_arm arm[] = {
597  (Odr_fun) z_External, "databaseRecord"},
599  (Odr_fun) z_DiagRec, "surrogateDiagnostic"},
601  (Odr_fun) z_FragmentSyntax, "startingFragment"},
603  (Odr_fun) z_FragmentSyntax, "intermediateFragment"},
605  (Odr_fun) z_FragmentSyntax, "finalFragment"},
606  {-1, -1, -1, -1, (Odr_fun) 0, 0}
607  };
608  if (!odr_sequence_begin(o, p, sizeof(**p), name))
609  return odr_missing(o, opt, name) && odr_ok (o);
610  return
612  &(*p)->databaseName, ODR_CONTEXT, 0, 1, "databaseName") &&
613  odr_constructed_begin(o, &(*p)->u, ODR_CONTEXT, 1, "record") &&
614  odr_choice(o, arm, &(*p)->u, &(*p)->which, 0) &&
615  odr_constructed_end(o) &&
616  odr_sequence_end(o);
617 }
618 
619 int z_FragmentSyntax(ODR o, Z_FragmentSyntax **p, int opt, const char *name)
620 {
621  static Odr_arm arm[] = {
623  (Odr_fun) z_External, "externallyTagged"},
625  (Odr_fun) odr_octetstring, "notExternallyTagged"},
626  {-1, -1, -1, -1, (Odr_fun) 0, 0}
627  };
628  if (!odr_initmember(o, p, sizeof(**p)))
629  return odr_missing(o, opt, name);
630  if (odr_choice(o, arm, &(*p)->u, &(*p)->which, name))
631  return 1;
632  if (o->direction == ODR_DECODE)
633  *p = 0;
634  return odr_missing(o, opt, name);
635 }
636 
637 int z_DiagRec(ODR o, Z_DiagRec **p, int opt, const char *name)
638 {
639  static Odr_arm arm[] = {
640  {-1, -1, -1, Z_DiagRec_defaultFormat,
641  (Odr_fun) z_DefaultDiagFormat, "defaultFormat"},
642  {-1, -1, -1, Z_DiagRec_externallyDefined,
643  (Odr_fun) z_External, "externallyDefined"},
644  {-1, -1, -1, -1, (Odr_fun) 0, 0}
645  };
646  if (!odr_initmember(o, p, sizeof(**p)))
647  return odr_missing(o, opt, name);
648  if (odr_choice(o, arm, &(*p)->u, &(*p)->which, name))
649  return 1;
650  if (o->direction == ODR_DECODE)
651  *p = 0;
652  return odr_missing(o, opt, name);
653 }
654 
655 int z_DefaultDiagFormat(ODR o, Z_DefaultDiagFormat **p, int opt, const char *name)
656 {
657  static Odr_arm arm[] = {
658  {-1, -1, -1, Z_DefaultDiagFormat_v2Addinfo,
659  (Odr_fun) odr_visiblestring, "v2Addinfo"},
660  {-1, -1, -1, Z_DefaultDiagFormat_v3Addinfo,
661  (Odr_fun) z_InternationalString, "v3Addinfo"},
662  {-1, -1, -1, -1, (Odr_fun) 0, 0}
663  };
664  if (!odr_sequence_begin(o, p, sizeof(**p), name))
665  return odr_missing(o, opt, name) && odr_ok (o);
666  return
667  odr_oid(o, &(*p)->diagnosticSetId, 0, "diagnosticSetId") &&
668  odr_integer(o, &(*p)->condition, 0, "condition") &&
669  odr_choice(o, arm, &(*p)->u, &(*p)->which, 0) &&
670  odr_sequence_end(o);
671 }
672 
673 int z_Range(ODR o, Z_Range **p, int opt, const char *name)
674 {
675  if (!odr_sequence_begin(o, p, sizeof(**p), name))
676  return odr_missing(o, opt, name) && odr_ok (o);
677  return
679  &(*p)->startingPosition, ODR_CONTEXT, 1, 0, "startingPosition") &&
681  &(*p)->numberOfRecords, ODR_CONTEXT, 2, 0, "numberOfRecords") &&
682  odr_sequence_end(o);
683 }
684 
686 {
687  if (!odr_sequence_begin(o, p, sizeof(**p), name))
688  return odr_missing(o, opt, name) && odr_ok (o);
689  return
690  z_DatabaseName(o, &(*p)->dbName, 0, "dbName") &&
691  z_ElementSetName(o, &(*p)->esn, 0, "esn") &&
692  odr_sequence_end(o);
693 }
694 
695 int z_DatabaseSpecific(ODR o, Z_DatabaseSpecific **p, int opt, const char *name)
696 {
697  if (!odr_initmember(o, p, sizeof(**p)))
698  return odr_missing(o, opt, name);
699  if (odr_sequence_of(o, (Odr_fun) z_DatabaseSpecificUnit, &(*p)->elements,
700  &(*p)->num, name))
701  return 1;
702  if (o->direction == ODR_DECODE)
703  *p = 0;
704  return odr_missing(o, opt, name);
705 }
706 
707 int z_ElementSetNames(ODR o, Z_ElementSetNames **p, int opt, const char *name)
708 {
709  static Odr_arm arm[] = {
711  (Odr_fun) z_InternationalString, "generic"},
713  (Odr_fun) z_DatabaseSpecific, "databaseSpecific"},
714  {-1, -1, -1, -1, (Odr_fun) 0, 0}
715  };
716  if (!odr_initmember(o, p, sizeof(**p)))
717  return odr_missing(o, opt, name);
718  if (odr_choice(o, arm, &(*p)->u, &(*p)->which, name))
719  return 1;
720  if (o->direction == ODR_DECODE)
721  *p = 0;
722  return odr_missing(o, opt, name);
723 }
724 
725 int z_PresentStatus(ODR o, Z_PresentStatus **p, int opt, const char *name)
726 {
727  return odr_implicit_tag(o, odr_integer, p, ODR_CONTEXT, 27, opt, name);
728 }
729 
730 int z_DbSpecific(ODR o, Z_DbSpecific **p, int opt, const char *name)
731 {
732  if (!odr_sequence_begin(o, p, sizeof(**p), name))
733  return odr_missing(o, opt, name) && odr_ok (o);
734  return
736  &(*p)->db, ODR_CONTEXT, 1, 0, "db") &&
738  &(*p)->spec, ODR_CONTEXT, 2, 0, "spec") &&
739  odr_sequence_end(o);
740 }
741 
742 int z_CompSpec(ODR o, Z_CompSpec **p, int opt, const char *name)
743 {
744  if (!odr_sequence_begin(o, p, sizeof(**p), name))
745  return odr_missing(o, opt, name) && odr_ok (o);
746  return
748  &(*p)->selectAlternativeSyntax, ODR_CONTEXT, 1, 0, "selectAlternativeSyntax") &&
750  &(*p)->generic, ODR_CONTEXT, 2, 1, "generic") &&
752  (odr_sequence_of(o, (Odr_fun) z_DbSpecific, &(*p)->dbSpecific,
753  &(*p)->num_dbSpecific, "dbSpecific") || odr_ok(o)) &&
755  (odr_sequence_of(o, (Odr_fun) odr_oid, &(*p)->recordSyntax,
756  &(*p)->num_recordSyntax, "recordSyntax") || odr_ok(o)) &&
757  odr_sequence_end(o);
758 }
759 
760 int z_ElementSpec(ODR o, Z_ElementSpec **p, int opt, const char *name)
761 {
762  static Odr_arm arm[] = {
764  (Odr_fun) z_InternationalString, "elementSetName"},
766  (Odr_fun) z_External, "externalSpec"},
767  {-1, -1, -1, -1, (Odr_fun) 0, 0}
768  };
769  if (!odr_initmember(o, p, sizeof(**p)))
770  return odr_missing(o, opt, name);
771  if (odr_choice(o, arm, &(*p)->u, &(*p)->which, name))
772  return 1;
773  if (o->direction == ODR_DECODE)
774  *p = 0;
775  return odr_missing(o, opt, name);
776 }
777 
778 int z_Specification(ODR o, Z_Specification **p, int opt, const char *name)
779 {
780  static Odr_arm arm[] = {
782  (Odr_fun) odr_oid, "oid"},
784  (Odr_fun) z_InternationalString, "uri"},
785  {-1, -1, -1, -1, (Odr_fun) 0, 0}
786  };
787  if (!odr_sequence_begin(o, p, sizeof(**p), name))
788  return odr_missing(o, opt, name) && odr_ok (o);
789  return
790  (odr_choice(o, arm, &(*p)->schema, &(*p)->which, 0) || odr_ok(o)) &&
792  &(*p)->elementSpec, ODR_CONTEXT, 2, 1, "elementSpec") &&
793  odr_sequence_end(o);
794 }
795 
797 {
798  if (!odr_sequence_begin(o, p, sizeof(**p), name))
799  return odr_missing(o, opt, name) && odr_ok (o);
800  return
801  z_ReferenceId(o, &(*p)->referenceId, 1, "referenceId") &&
803  &(*p)->deleteFunction, ODR_CONTEXT, 32, 0, "deleteFunction") &&
804  (odr_sequence_of(o, (Odr_fun) z_ResultSetId, &(*p)->resultSetList,
805  &(*p)->num_resultSetList, "resultSetList") || odr_ok(o)) &&
806  z_OtherInformation(o, &(*p)->otherInfo, 1, "otherInfo") &&
807  odr_sequence_end(o);
808 }
809 
811 {
812  if (!odr_sequence_begin(o, p, sizeof(**p), name))
813  return odr_missing(o, opt, name) && odr_ok (o);
814  return
815  z_ReferenceId(o, &(*p)->referenceId, 1, "referenceId") &&
817  &(*p)->deleteOperationStatus, ODR_CONTEXT, 0, 0, "deleteOperationStatus") &&
819  &(*p)->deleteListStatuses, ODR_CONTEXT, 1, 1, "deleteListStatuses") &&
821  &(*p)->numberNotDeleted, ODR_CONTEXT, 34, 1, "numberNotDeleted") &&
823  &(*p)->bulkStatuses, ODR_CONTEXT, 35, 1, "bulkStatuses") &&
825  &(*p)->deleteMessage, ODR_CONTEXT, 36, 1, "deleteMessage") &&
826  z_OtherInformation(o, &(*p)->otherInfo, 1, "otherInfo") &&
827  odr_sequence_end(o);
828 }
829 
830 int z_ListStatus(ODR o, Z_ListStatus **p, int opt, const char *name)
831 {
832  if (!odr_sequence_begin(o, p, sizeof(**p), name))
833  return odr_missing(o, opt, name) && odr_ok (o);
834  return
835  z_ResultSetId(o, &(*p)->id, 0, "id") &&
836  z_DeleteStatus(o, &(*p)->status, 0, "status") &&
837  odr_sequence_end(o);
838 }
839 
840 int z_ListStatuses(ODR o, Z_ListStatuses **p, int opt, const char *name)
841 {
842  if (!odr_initmember(o, p, sizeof(**p)))
843  return odr_missing(o, opt, name);
844  if (odr_sequence_of(o, (Odr_fun) z_ListStatus, &(*p)->elements,
845  &(*p)->num, name))
846  return 1;
847  if (o->direction == ODR_DECODE)
848  *p = 0;
849  return odr_missing(o, opt, name);
850 }
851 
852 int z_DeleteStatus(ODR o, Z_DeleteStatus **p, int opt, const char *name)
853 {
854  return odr_implicit_tag(o, odr_integer, p, ODR_CONTEXT, 33, opt, name);
855 }
856 
858 {
859  static Odr_arm arm[] = {
861  (Odr_fun) odr_octetstring, "simpleForm"},
863  (Odr_fun) z_External, "externallyDefined"},
864  {-1, -1, -1, -1, (Odr_fun) 0, 0}
865  };
866  if (!odr_sequence_begin(o, p, sizeof(**p), name))
867  return odr_missing(o, opt, name) && odr_ok (o);
868  return
869  z_ReferenceId(o, &(*p)->referenceId, 1, "referenceId") &&
870  odr_choice(o, arm, &(*p)->u, &(*p)->which, 0) &&
871  z_OtherInformation(o, &(*p)->otherInfo, 1, "otherInfo") &&
872  odr_sequence_end(o);
873 }
874 
876 {
877  static Odr_arm arm[] = {
879  (Odr_fun) odr_octetstring, "simpleForm"},
881  (Odr_fun) z_External, "externallyDefined"},
882  {-1, -1, -1, -1, (Odr_fun) 0, 0}
883  };
884  if (!odr_sequence_begin(o, p, sizeof(**p), name))
885  return odr_missing(o, opt, name) && odr_ok (o);
886  return
887  z_ReferenceId(o, &(*p)->referenceId, 1, "referenceId") &&
888  (odr_choice(o, arm, &(*p)->u, &(*p)->which, 0) || odr_ok(o)) &&
890  &(*p)->diagnostic, ODR_CONTEXT, 223, 1, "diagnostic") &&
891  z_OtherInformation(o, &(*p)->otherInfo, 1, "otherInfo") &&
892  odr_sequence_end(o);
893 }
894 
896 {
897  if (!odr_sequence_begin(o, p, sizeof(**p), name))
898  return odr_missing(o, opt, name) && odr_ok (o);
899  return
900  z_ReferenceId(o, &(*p)->referenceId, 1, "referenceId") &&
902  &(*p)->suspendedFlag, ODR_CONTEXT, 39, 1, "suspendedFlag") &&
904  &(*p)->resourceReport, ODR_CONTEXT, 40, 1, "resourceReport") &&
906  &(*p)->partialResultsAvailable, ODR_CONTEXT, 41, 1, "partialResultsAvailable") &&
908  &(*p)->responseRequired, ODR_CONTEXT, 42, 0, "responseRequired") &&
910  &(*p)->triggeredRequestFlag, ODR_CONTEXT, 43, 1, "triggeredRequestFlag") &&
911  z_OtherInformation(o, &(*p)->otherInfo, 1, "otherInfo") &&
912  odr_sequence_end(o);
913 }
914 
916 {
917  if (!odr_sequence_begin(o, p, sizeof(**p), name))
918  return odr_missing(o, opt, name) && odr_ok (o);
919  return
920  z_ReferenceId(o, &(*p)->referenceId, 1, "referenceId") &&
922  &(*p)->continueFlag, ODR_CONTEXT, 44, 0, "continueFlag") &&
924  &(*p)->resultSetWanted, ODR_CONTEXT, 45, 1, "resultSetWanted") &&
925  z_OtherInformation(o, &(*p)->otherInfo, 1, "otherInfo") &&
926  odr_sequence_end(o);
927 }
928 
930 {
931  if (!odr_sequence_begin(o, p, sizeof(**p), name))
932  return odr_missing(o, opt, name) && odr_ok (o);
933  return
934  z_ReferenceId(o, &(*p)->referenceId, 1, "referenceId") &&
936  &(*p)->requestedAction, ODR_CONTEXT, 46, 0, "requestedAction") &&
938  &(*p)->prefResourceReportFormat, ODR_CONTEXT, 47, 1, "prefResourceReportFormat") &&
940  &(*p)->resultSetWanted, ODR_CONTEXT, 48, 1, "resultSetWanted") &&
941  z_OtherInformation(o, &(*p)->otherInfo, 1, "otherInfo") &&
942  odr_sequence_end(o);
943 }
944 
946 {
947  if (!odr_sequence_begin(o, p, sizeof(**p), name))
948  return odr_missing(o, opt, name) && odr_ok (o);
949  return
950  z_ReferenceId(o, &(*p)->referenceId, 1, "referenceId") &&
952  &(*p)->opId, ODR_CONTEXT, 210, 1, "opId") &&
954  &(*p)->prefResourceReportFormat, ODR_CONTEXT, 49, 1, "prefResourceReportFormat") &&
955  z_OtherInformation(o, &(*p)->otherInfo, 1, "otherInfo") &&
956  odr_sequence_end(o);
957 }
958 
960 {
961  if (!odr_sequence_begin(o, p, sizeof(**p), name))
962  return odr_missing(o, opt, name) && odr_ok (o);
963  return
964  z_ReferenceId(o, &(*p)->referenceId, 1, "referenceId") &&
966  &(*p)->resourceReportStatus, ODR_CONTEXT, 50, 0, "resourceReportStatus") &&
968  &(*p)->resourceReport, ODR_CONTEXT, 51, 1, "resourceReport") &&
969  z_OtherInformation(o, &(*p)->otherInfo, 1, "otherInfo") &&
970  odr_sequence_end(o);
971 }
972 
973 int z_ResourceReport(ODR o, Z_ResourceReport **p, int opt, const char *name)
974 {
975  return z_External (o, p, opt, name);
976 }
977 
978 int z_ResourceReportId(ODR o, Z_ResourceReportId **p, int opt, const char *name)
979 {
980  return odr_oid (o, p, opt, name);
981 }
982 
983 int z_ScanRequest(ODR o, Z_ScanRequest **p, int opt, const char *name)
984 {
985  if (!odr_sequence_begin(o, p, sizeof(**p), name))
986  return odr_missing(o, opt, name) && odr_ok (o);
987  return
988  z_ReferenceId(o, &(*p)->referenceId, 1, "referenceId") &&
990  odr_sequence_of(o, (Odr_fun) z_DatabaseName, &(*p)->databaseNames,
991  &(*p)->num_databaseNames, "databaseNames") &&
992  z_AttributeSetId(o, &(*p)->attributeSet, 1, "attributeSet") &&
993  z_AttributesPlusTerm(o, &(*p)->termListAndStartPoint, 0, "termListAndStartPoint") &&
995  &(*p)->stepSize, ODR_CONTEXT, 5, 1, "stepSize") &&
997  &(*p)->numberOfTermsRequested, ODR_CONTEXT, 6, 0, "numberOfTermsRequested") &&
999  &(*p)->preferredPositionInResponse, ODR_CONTEXT, 7, 1, "preferredPositionInResponse") &&
1000  z_OtherInformation(o, &(*p)->otherInfo, 1, "otherInfo") &&
1001  odr_sequence_end(o);
1002 }
1003 
1004 int z_ScanResponse(ODR o, Z_ScanResponse **p, int opt, const char *name)
1005 {
1006  if (!odr_sequence_begin(o, p, sizeof(**p), name))
1007  return odr_missing(o, opt, name) && odr_ok (o);
1008  return
1009  z_ReferenceId(o, &(*p)->referenceId, 1, "referenceId") &&
1011  &(*p)->stepSize, ODR_CONTEXT, 3, 1, "stepSize") &&
1013  &(*p)->scanStatus, ODR_CONTEXT, 4, 0, "scanStatus") &&
1015  &(*p)->numberOfEntriesReturned, ODR_CONTEXT, 5, 0, "numberOfEntriesReturned") &&
1017  &(*p)->positionOfTerm, ODR_CONTEXT, 6, 1, "positionOfTerm") &&
1019  &(*p)->entries, ODR_CONTEXT, 7, 1, "entries") &&
1021  &(*p)->attributeSet, ODR_CONTEXT, 8, 1, "attributeSet") &&
1022  z_OtherInformation(o, &(*p)->otherInfo, 1, "otherInfo") &&
1023  odr_sequence_end(o);
1024 }
1025 
1026 int z_ListEntries(ODR o, Z_ListEntries **p, int opt, const char *name)
1027 {
1028  if (!odr_sequence_begin(o, p, sizeof(**p), name))
1029  return odr_missing(o, opt, name) && odr_ok (o);
1030  return
1032  (odr_sequence_of(o, (Odr_fun) z_Entry, &(*p)->entries,
1033  &(*p)->num_entries, "entries") || odr_ok(o)) &&
1035  (odr_sequence_of(o, (Odr_fun) z_DiagRec, &(*p)->nonsurrogateDiagnostics,
1036  &(*p)->num_nonsurrogateDiagnostics, "nonsurrogateDiagnostics") || odr_ok(o)) &&
1037  odr_sequence_end(o);
1038 }
1039 
1040 int z_Entry(ODR o, Z_Entry **p, int opt, const char *name)
1041 {
1042  static Odr_arm arm[] = {
1044  (Odr_fun) z_TermInfo, "termInfo"},
1046  (Odr_fun) z_DiagRec, "surrogateDiagnostic"},
1047  {-1, -1, -1, -1, (Odr_fun) 0, 0}
1048  };
1049  if (!odr_initmember(o, p, sizeof(**p)))
1050  return odr_missing(o, opt, name);
1051  if (odr_choice(o, arm, &(*p)->u, &(*p)->which, name))
1052  return 1;
1053  if (o->direction == ODR_DECODE)
1054  *p = 0;
1055  return odr_missing(o, opt, name);
1056 }
1057 
1058 int z_TermInfo(ODR o, Z_TermInfo **p, int opt, const char *name)
1059 {
1060  if (!odr_sequence_begin(o, p, sizeof(**p), name))
1061  return odr_missing(o, opt, name) && odr_ok (o);
1062  return
1063  z_Term(o, &(*p)->term, 0, "term") &&
1065  &(*p)->displayTerm, ODR_CONTEXT, 0, 1, "displayTerm") &&
1066  z_AttributeList(o, &(*p)->suggestedAttributes, 1, "suggestedAttributes") &&
1068  (odr_sequence_of(o, (Odr_fun) z_AttributesPlusTerm, &(*p)->alternativeTerm,
1069  &(*p)->num_alternativeTerm, "alternativeTerm") || odr_ok(o)) &&
1071  &(*p)->globalOccurrences, ODR_CONTEXT, 2, 1, "globalOccurrences") &&
1073  &(*p)->byAttributes, ODR_CONTEXT, 3, 1, "byAttributes") &&
1074  z_OtherInformation(o, &(*p)->otherTermInfo, 1, "otherTermInfo") &&
1075  odr_sequence_end(o);
1076 }
1077 
1078 int z_byDatabaseList_s(ODR o, Z_byDatabaseList_s **p, int opt, const char *name)
1079 {
1080  if (!odr_sequence_begin(o, p, sizeof(**p), name))
1081  return odr_missing(o, opt, name) && odr_ok (o);
1082  return
1083  z_DatabaseName(o, &(*p)->db, 0, "db") &&
1085  &(*p)->num, ODR_CONTEXT, 1, 1, "num") &&
1086  z_OtherInformation(o, &(*p)->otherDbInfo, 1, "otherDbInfo") &&
1087  odr_sequence_end(o);
1088 }
1089 
1090 int z_byDatabaseList(ODR o, Z_byDatabaseList **p, int opt, const char *name)
1091 {
1092  if (!odr_initmember(o, p, sizeof(**p)))
1093  return odr_missing(o, opt, name);
1094  if (odr_sequence_of(o, (Odr_fun) z_byDatabaseList_s, &(*p)->elements,
1095  &(*p)->num, name))
1096  return 1;
1097  if (o->direction == ODR_DECODE)
1098  *p = 0;
1099  return odr_missing(o, opt, name);
1100 }
1101 
1103 {
1104  static Odr_arm arm[] = {
1106  (Odr_fun) odr_integer, "global"},
1108  (Odr_fun) z_byDatabaseList, "byDatabase"},
1109  {-1, -1, -1, -1, (Odr_fun) 0, 0}
1110  };
1111  if (!odr_sequence_begin(o, p, sizeof(**p), name))
1112  return odr_missing(o, opt, name) && odr_ok (o);
1113  return
1115  &(*p)->attributes, ODR_CONTEXT, 1, 0, "attributes") &&
1116  (odr_choice(o, arm, &(*p)->u, &(*p)->which, 0) || odr_ok(o)) &&
1117  z_OtherInformation(o, &(*p)->otherOccurInfo, 1, "otherOccurInfo") &&
1118  odr_sequence_end(o);
1119 }
1120 
1122 {
1123  if (!odr_initmember(o, p, sizeof(**p)))
1124  return odr_missing(o, opt, name);
1125  if (odr_sequence_of(o, (Odr_fun) z_OccurrenceByAttributesElem, &(*p)->elements,
1126  &(*p)->num, name))
1127  return 1;
1128  if (o->direction == ODR_DECODE)
1129  *p = 0;
1130  return odr_missing(o, opt, name);
1131 }
1132 
1133 int z_SortKeySpecList(ODR o, Z_SortKeySpecList **p, int opt, const char *name)
1134 {
1135  if (!odr_initmember(o, p, sizeof(**p)))
1136  return odr_missing(o, opt, name);
1137  if (odr_sequence_of(o, (Odr_fun) z_SortKeySpec, &(*p)->specs,
1138  &(*p)->num_specs, name))
1139  return 1;
1140  if (o->direction == ODR_DECODE)
1141  *p = 0;
1142  return odr_missing(o, opt, name);
1143 }
1144 
1145 int z_SortRequest(ODR o, Z_SortRequest **p, int opt, const char *name)
1146 {
1147  if (!odr_sequence_begin(o, p, sizeof(**p), name))
1148  return odr_missing(o, opt, name) && odr_ok (o);
1149  return
1150  z_ReferenceId(o, &(*p)->referenceId, 1, "referenceId") &&
1152  odr_sequence_of(o, (Odr_fun) z_InternationalString, &(*p)->inputResultSetNames,
1153  &(*p)->num_inputResultSetNames, "inputResultSetNames") &&
1154  odr_implicit_tag(o, z_InternationalString,
1155  &(*p)->sortedResultSetName, ODR_CONTEXT, 4, 0, "sortedResultSetName") &&
1157  &(*p)->sortSequence, ODR_CONTEXT, 5, 0, "sortSequence") &&
1158  z_OtherInformation(o, &(*p)->otherInfo, 1, "otherInfo") &&
1159  odr_sequence_end(o);
1160 }
1161 
1162 int z_SortResponse(ODR o, Z_SortResponse **p, int opt, const char *name)
1163 {
1164  if (!odr_sequence_begin(o, p, sizeof(**p), name))
1165  return odr_missing(o, opt, name) && odr_ok (o);
1166  return
1167  z_ReferenceId(o, &(*p)->referenceId, 1, "referenceId") &&
1169  &(*p)->sortStatus, ODR_CONTEXT, 3, 0, "sortStatus") &&
1171  &(*p)->resultSetStatus, ODR_CONTEXT, 4, 1, "resultSetStatus") &&
1173  (odr_sequence_of(o, (Odr_fun) z_DiagRec, &(*p)->diagnostics,
1174  &(*p)->num_diagnostics, "diagnostics") || odr_ok(o)) &&
1176  &(*p)->resultCount, ODR_CONTEXT, 6, 1, "resultCount") &&
1177  z_OtherInformation(o, &(*p)->otherInfo, 1, "otherInfo") &&
1178  odr_sequence_end(o);
1179 }
1180 
1181 int z_SortKeySpec(ODR o, Z_SortKeySpec **p, int opt, const char *name)
1182 {
1183  static Odr_arm arm[] = {
1185  (Odr_fun) odr_null, "abort"},
1187  (Odr_fun) odr_null, "null"},
1189  (Odr_fun) odr_octetstring, "missingValueData"},
1190  {-1, -1, -1, -1, (Odr_fun) 0, 0}
1191  };
1192  if (!odr_sequence_begin(o, p, sizeof(**p), name))
1193  return odr_missing(o, opt, name) && odr_ok (o);
1194  return
1195  z_SortElement(o, &(*p)->sortElement, 0, "sortElement") &&
1197  &(*p)->sortRelation, ODR_CONTEXT, 1, 0, "sortRelation") &&
1199  &(*p)->caseSensitivity, ODR_CONTEXT, 2, 0, "caseSensitivity") &&
1200  ((odr_constructed_begin(o, &(*p)->u, ODR_CONTEXT, 3, "missingValueAction") &&
1201  odr_choice(o, arm, &(*p)->u, &(*p)->which, 0) &&
1202  odr_constructed_end(o)) || odr_ok(o)) &&
1203  odr_sequence_end(o);
1204 }
1205 
1207 {
1208  if (!odr_sequence_begin(o, p, sizeof(**p), name))
1209  return odr_missing(o, opt, name) && odr_ok (o);
1210  return
1211  z_DatabaseName(o, &(*p)->databaseName, 0, "databaseName") &&
1212  z_SortKey(o, &(*p)->dbSort, 0, "dbSort") &&
1213  odr_sequence_end(o);
1214 }
1215 
1217 {
1218  if (!odr_initmember(o, p, sizeof(**p)))
1219  return odr_missing(o, opt, name);
1220  if (odr_sequence_of(o, (Odr_fun) z_SortDbSpecificList_s, &(*p)->elements,
1221  &(*p)->num, name))
1222  return 1;
1223  if (o->direction == ODR_DECODE)
1224  *p = 0;
1225  return odr_missing(o, opt, name);
1226 }
1227 
1228 int z_SortElement(ODR o, Z_SortElement **p, int opt, const char *name)
1229 {
1230  static Odr_arm arm[] = {
1232  (Odr_fun) z_SortKey, "generic"},
1234  (Odr_fun) z_SortDbSpecificList, "databaseSpecific"},
1235  {-1, -1, -1, -1, (Odr_fun) 0, 0}
1236  };
1237  if (!odr_initmember(o, p, sizeof(**p)))
1238  return odr_missing(o, opt, name);
1239  if (odr_choice(o, arm, &(*p)->u, &(*p)->which, name))
1240  return 1;
1241  if (o->direction == ODR_DECODE)
1242  *p = 0;
1243  return odr_missing(o, opt, name);
1244 }
1245 
1246 int z_SortAttributes(ODR o, Z_SortAttributes **p, int opt, const char *name)
1247 {
1248  if (!odr_sequence_begin(o, p, sizeof(**p), name))
1249  return odr_missing(o, opt, name) && odr_ok (o);
1250  return
1251  z_AttributeSetId(o, &(*p)->id, 0, "id") &&
1252  z_AttributeList(o, &(*p)->list, 0, "list") &&
1253  odr_sequence_end(o);
1254 }
1255 
1256 int z_SortKey(ODR o, Z_SortKey **p, int opt, const char *name)
1257 {
1258  static Odr_arm arm[] = {
1260  (Odr_fun) z_InternationalString, "sortField"},
1262  (Odr_fun) z_Specification, "elementSpec"},
1264  (Odr_fun) z_SortAttributes, "sortAttributes"},
1265  {-1, -1, -1, -1, (Odr_fun) 0, 0}
1266  };
1267  if (!odr_initmember(o, p, sizeof(**p)))
1268  return odr_missing(o, opt, name);
1269  if (odr_choice(o, arm, &(*p)->u, &(*p)->which, name))
1270  return 1;
1271  if (o->direction == ODR_DECODE)
1272  *p = 0;
1273  return odr_missing(o, opt, name);
1274 }
1275 
1277 {
1278  if (!odr_sequence_begin(o, p, sizeof(**p), name))
1279  return odr_missing(o, opt, name) && odr_ok (o);
1280  return
1281  z_ReferenceId(o, &(*p)->referenceId, 1, "referenceId") &&
1283  &(*p)->function, ODR_CONTEXT, 3, 0, "function") &&
1285  &(*p)->packageType, ODR_CONTEXT, 4, 0, "packageType") &&
1287  &(*p)->packageName, ODR_CONTEXT, 5, 1, "packageName") &&
1289  &(*p)->userId, ODR_CONTEXT, 6, 1, "userId") &&
1291  &(*p)->retentionTime, ODR_CONTEXT, 7, 1, "retentionTime") &&
1293  &(*p)->permissions, ODR_CONTEXT, 8, 1, "permissions") &&
1295  &(*p)->description, ODR_CONTEXT, 9, 1, "description") &&
1297  &(*p)->taskSpecificParameters, ODR_CONTEXT, 10, 1, "taskSpecificParameters") &&
1299  &(*p)->waitAction, ODR_CONTEXT, 11, 0, "waitAction") &&
1300  z_ElementSetName(o, &(*p)->elements, 1, "elements") &&
1301  z_OtherInformation(o, &(*p)->otherInfo, 1, "otherInfo") &&
1302  odr_sequence_end(o);
1303 }
1304 
1306 {
1307  if (!odr_sequence_begin(o, p, sizeof(**p), name))
1308  return odr_missing(o, opt, name) && odr_ok (o);
1309  return
1310  z_ReferenceId(o, &(*p)->referenceId, 1, "referenceId") &&
1312  &(*p)->operationStatus, ODR_CONTEXT, 3, 0, "operationStatus") &&
1314  (odr_sequence_of(o, (Odr_fun) z_DiagRec, &(*p)->diagnostics,
1315  &(*p)->num_diagnostics, "diagnostics") || odr_ok(o)) &&
1317  &(*p)->taskPackage, ODR_CONTEXT, 5, 1, "taskPackage") &&
1318  z_OtherInformation(o, &(*p)->otherInfo, 1, "otherInfo") &&
1319  odr_sequence_end(o);
1320 }
1321 
1322 int z_Permissions_s(ODR o, Z_Permissions_s **p, int opt, const char *name)
1323 {
1324  if (!odr_sequence_begin(o, p, sizeof(**p), name))
1325  return odr_missing(o, opt, name) && odr_ok (o);
1326  return
1328  &(*p)->userId, ODR_CONTEXT, 1, 1, "userId") &&
1330  odr_sequence_of(o, (Odr_fun) odr_integer, &(*p)->allowableFunctions,
1331  &(*p)->num_allowableFunctions, "allowableFunctions") &&
1332  odr_sequence_end(o);
1333 }
1334 
1335 int z_Permissions(ODR o, Z_Permissions **p, int opt, const char *name)
1336 {
1337  if (!odr_initmember(o, p, sizeof(**p)))
1338  return odr_missing(o, opt, name);
1339  if (odr_sequence_of(o, (Odr_fun) z_Permissions_s, &(*p)->elements,
1340  &(*p)->num, name))
1341  return 1;
1342  if (o->direction == ODR_DECODE)
1343  *p = 0;
1344  return odr_missing(o, opt, name);
1345 }
1346 
1347 int z_Close(ODR o, Z_Close **p, int opt, const char *name)
1348 {
1349  if (!odr_sequence_begin(o, p, sizeof(**p), name))
1350  return odr_missing(o, opt, name) && odr_ok (o);
1351  return
1352  z_ReferenceId(o, &(*p)->referenceId, 1, "referenceId") &&
1353  z_CloseReason(o, &(*p)->closeReason, 0, "closeReason") &&
1355  &(*p)->diagnosticInformation, ODR_CONTEXT, 3, 1, "diagnosticInformation") &&
1357  &(*p)->resourceReportFormat, ODR_CONTEXT, 4, 1, "resourceReportFormat") &&
1359  &(*p)->resourceReport, ODR_CONTEXT, 5, 1, "resourceReport") &&
1360  z_OtherInformation(o, &(*p)->otherInfo, 1, "otherInfo") &&
1361  odr_sequence_end(o);
1362 }
1363 
1364 int z_CloseReason(ODR o, Z_CloseReason **p, int opt, const char *name)
1365 {
1366  return odr_implicit_tag(o, odr_integer, p, ODR_CONTEXT, 211, opt, name);
1367 }
1368 
1370 {
1371  if (!odr_sequence_begin(o, p, sizeof(**p), name))
1372  return odr_missing(o, opt, name) && odr_ok (o);
1373  return
1374  z_ReferenceId(o, &(*p)->referenceId, 1, "referenceId") &&
1376  odr_sequence_of(o, (Odr_fun) z_InternationalString, &(*p)->inputResultSetIds,
1377  &(*p)->num_inputResultSetIds, "inputResultSetIds") &&
1378  odr_implicit_tag(o, z_InternationalString,
1379  &(*p)->outputResultSetName, ODR_CONTEXT, 4, 0, "outputResultSetName") &&
1381  &(*p)->applicablePortionOfRecord, ODR_CONTEXT, 5, 1, "applicablePortionOfRecord") &&
1383  (odr_sequence_of(o, (Odr_fun) z_DuplicateDetectionCriterion, &(*p)->duplicateDetectionCriteria,
1384  &(*p)->num_duplicateDetectionCriteria, "duplicateDetectionCriteria") || odr_ok(o)) &&
1386  &(*p)->clustering, ODR_CONTEXT, 7, 1, "clustering") &&
1388  odr_sequence_of(o, (Odr_fun) z_RetentionCriterion, &(*p)->retentionCriteria,
1389  &(*p)->num_retentionCriteria, "retentionCriteria") &&
1391  (odr_sequence_of(o, (Odr_fun) z_SortCriterion, &(*p)->sortCriteria,
1392  &(*p)->num_sortCriteria, "sortCriteria") || odr_ok(o)) &&
1393  z_OtherInformation(o, &(*p)->otherInfo, 1, "otherInfo") &&
1394  odr_sequence_end(o);
1395 }
1396 
1398 {
1399  static Odr_arm arm[] = {
1401  (Odr_fun) odr_integer, "levelOfMatch"},
1403  (Odr_fun) odr_null, "caseSensitive"},
1405  (Odr_fun) odr_null, "punctuationSensitive"},
1407  (Odr_fun) z_External, "regularExpression"},
1409  (Odr_fun) odr_null, "rsDuplicates"},
1410  {-1, -1, -1, -1, (Odr_fun) 0, 0}
1411  };
1412  if (!odr_initmember(o, p, sizeof(**p)))
1413  return odr_missing(o, opt, name);
1414  if (odr_choice(o, arm, &(*p)->u, &(*p)->which, name))
1415  return 1;
1416  if (o->direction == ODR_DECODE)
1417  *p = 0;
1418  return odr_missing(o, opt, name);
1419 }
1420 
1422 {
1423  static Odr_arm arm[] = {
1425  (Odr_fun) odr_integer, "numberOfEntries"},
1427  (Odr_fun) odr_integer, "percentOfEntries"},
1429  (Odr_fun) odr_null, "duplicatesOnly"},
1431  (Odr_fun) odr_null, "discardRsDuplicates"},
1432  {-1, -1, -1, -1, (Odr_fun) 0, 0}
1433  };
1434  if (!odr_initmember(o, p, sizeof(**p)))
1435  return odr_missing(o, opt, name);
1436  if (odr_choice(o, arm, &(*p)->u, &(*p)->which, name))
1437  return 1;
1438  if (o->direction == ODR_DECODE)
1439  *p = 0;
1440  return odr_missing(o, opt, name);
1441 }
1442 
1444 {
1445  if (!odr_initmember(o, p, sizeof(**p)))
1446  return odr_missing(o, opt, name);
1447  if (odr_sequence_of(o, (Odr_fun) z_InternationalString, &(*p)->elements,
1448  &(*p)->num, name))
1449  return 1;
1450  if (o->direction == ODR_DECODE)
1451  *p = 0;
1452  return odr_missing(o, opt, name);
1453 }
1454 
1455 int z_SortCriterion(ODR o, Z_SortCriterion **p, int opt, const char *name)
1456 {
1457  static Odr_arm arm[] = {
1459  (Odr_fun) odr_null, "mostComprehensive"},
1461  (Odr_fun) odr_null, "leastConmprehensive"},
1463  (Odr_fun) odr_null, "mostRecent"},
1465  (Odr_fun) odr_null, "oldest"},
1467  (Odr_fun) odr_null, "leastCost"},
1469  (Odr_fun) z_SortCriterionPreferredDatabases, "preferredDatabases"},
1470  {-1, -1, -1, -1, (Odr_fun) 0, 0}
1471  };
1472  if (!odr_initmember(o, p, sizeof(**p)))
1473  return odr_missing(o, opt, name);
1474  if (odr_choice(o, arm, &(*p)->u, &(*p)->which, name))
1475  return 1;
1476  if (o->direction == ODR_DECODE)
1477  *p = 0;
1478  return odr_missing(o, opt, name);
1479 }
1480 
1482 {
1483  if (!odr_sequence_begin(o, p, sizeof(**p), name))
1484  return odr_missing(o, opt, name) && odr_ok (o);
1485  return
1486  z_ReferenceId(o, &(*p)->referenceId, 1, "referenceId") &&
1488  &(*p)->status, ODR_CONTEXT, 3, 0, "status") &&
1490  &(*p)->resultSetCount, ODR_CONTEXT, 4, 1, "resultSetCount") &&
1492  (odr_sequence_of(o, (Odr_fun) z_DiagRec, &(*p)->diagnostics,
1493  &(*p)->num_diagnostics, "diagnostics") || odr_ok(o)) &&
1494  z_OtherInformation(o, &(*p)->otherInfo, 1, "otherInfo") &&
1495  odr_sequence_end(o);
1496 }
1497 
1498 int z_ReferenceId(ODR o, Z_ReferenceId **p, int opt, const char *name)
1499 {
1500  return odr_implicit_tag(o, odr_octetstring, p, ODR_CONTEXT, 2, opt, name);
1501 }
1502 
1503 int z_ResultSetId(ODR o, Z_ResultSetId **p, int opt, const char *name)
1504 {
1505  return odr_implicit_tag(o, z_InternationalString, p, ODR_CONTEXT, 31, opt, name);
1506 }
1507 
1508 int z_ElementSetName(ODR o, Z_ElementSetName **p, int opt, const char *name)
1509 {
1510  return odr_implicit_tag(o, z_InternationalString, p, ODR_CONTEXT, 103, opt, name);
1511 }
1512 
1513 int z_DatabaseName(ODR o, Z_DatabaseName **p, int opt, const char *name)
1514 {
1515  return odr_implicit_tag(o, z_InternationalString, p, ODR_CONTEXT, 105, opt, name);
1516 }
1517 
1518 int z_AttributeSetId(ODR o, Z_AttributeSetId **p, int opt, const char *name)
1519 {
1520  return odr_oid (o, p, opt, name);
1521 }
1522 
1524 {
1525  static Odr_arm arm[] = {
1527  (Odr_fun) z_InternationalString, "characterInfo"},
1529  (Odr_fun) odr_octetstring, "binaryInfo"},
1531  (Odr_fun) z_External, "externallyDefinedInfo"},
1533  (Odr_fun) odr_oid, "oid"},
1534  {-1, -1, -1, -1, (Odr_fun) 0, 0}
1535  };
1536  if (!odr_sequence_begin(o, p, sizeof(**p), name))
1537  return odr_missing(o, opt, name) && odr_ok (o);
1538  return
1540  &(*p)->category, ODR_CONTEXT, 1, 1, "category") &&
1541  odr_choice(o, arm, &(*p)->information, &(*p)->which, 0) &&
1542  odr_sequence_end(o);
1543 }
1544 
1545 int z_OtherInformation(ODR o, Z_OtherInformation **p, int opt, const char *name)
1546 {
1547  if (!odr_initmember(o, p, sizeof(**p)))
1548  return odr_missing(o, opt, name);
1550  if (odr_sequence_of(o, (Odr_fun) z_OtherInformationUnit, &(*p)->list,
1551  &(*p)->num_elements, name))
1552  return 1;
1553  if (o->direction == ODR_DECODE)
1554  *p = 0;
1555  return odr_missing(o, opt, name);
1556 }
1557 
1558 int z_InfoCategory(ODR o, Z_InfoCategory **p, int opt, const char *name)
1559 {
1560  if (!odr_sequence_begin(o, p, sizeof(**p), name))
1561  return odr_missing(o, opt, name) && odr_ok (o);
1562  return
1564  &(*p)->categoryTypeId, ODR_CONTEXT, 1, 1, "categoryTypeId") &&
1566  &(*p)->categoryValue, ODR_CONTEXT, 2, 0, "categoryValue") &&
1567  odr_sequence_end(o);
1568 }
1569 
1570 int z_IntUnit(ODR o, Z_IntUnit **p, int opt, const char *name)
1571 {
1572  if (!odr_sequence_begin(o, p, sizeof(**p), name))
1573  return odr_missing(o, opt, name) && odr_ok (o);
1574  return
1576  &(*p)->value, ODR_CONTEXT, 1, 0, "value") &&
1578  &(*p)->unitUsed, ODR_CONTEXT, 2, 0, "unitUsed") &&
1579  odr_sequence_end(o);
1580 }
1581 
1582 int z_Unit(ODR o, Z_Unit **p, int opt, const char *name)
1583 {
1584  if (!odr_sequence_begin(o, p, sizeof(**p), name))
1585  return odr_missing(o, opt, name) && odr_ok (o);
1586  return
1588  &(*p)->unitSystem, ODR_CONTEXT, 1, 1, "unitSystem") &&
1590  &(*p)->unitType, ODR_CONTEXT, 2, 1, "unitType") &&
1592  &(*p)->unit, ODR_CONTEXT, 3, 1, "unit") &&
1594  &(*p)->scaleFactor, ODR_CONTEXT, 4, 1, "scaleFactor") &&
1595  odr_sequence_end(o);
1596 }
1597 
1599 {
1600  return odr_generalstring (o, p, opt, name);
1601 }
1602 
1603 int z_StringOrNumeric(ODR o, Z_StringOrNumeric **p, int opt, const char *name)
1604 {
1605  static Odr_arm arm[] = {
1607  (Odr_fun) z_InternationalString, "string"},
1609  (Odr_fun) odr_integer, "numeric"},
1610  {-1, -1, -1, -1, (Odr_fun) 0, 0}
1611  };
1612  if (!odr_initmember(o, p, sizeof(**p)))
1613  return odr_missing(o, opt, name);
1614  if (odr_choice(o, arm, &(*p)->u, &(*p)->which, name))
1615  return 1;
1616  if (o->direction == ODR_DECODE)
1617  *p = 0;
1618  return odr_missing(o, opt, name);
1619 }
1620 
1621 
1622 /* the type-0 query ... */
1623 int z_ANY_type_0 (ODR o, void **p, int opt)
1624 {
1625  return 0;
1626 }
1627 
1628 
Odr_int Z_PresentStatus
Definition: z-core.h:133
#define odr_ok(o)
Definition: odr.h:215
#define Z_APDU_scanResponse
Definition: z-core.h:365
#define Z_AttributeValue_numeric
Definition: z-core.h:586
char Z_InternationalString
Definition: z-core.h:301
int z_IdPass(ODR o, Z_IdPass **p, int opt, const char *name)
Definition: z-core.c:102
#define Z_APDU_searchResponse
Definition: z-core.h:352
int z_AccessControlResponse(ODR o, Z_AccessControlResponse **p, int opt, const char *name)
Definition: z-core.c:875
int z_StringOrNumeric(ODR o, Z_StringOrNumeric **p, int opt, const char *name)
Definition: z-core.c:1603
int z_Operator(ODR o, Z_Operator **p, int opt, const char *name)
Definition: z-core.c:359
int z_AttributeList(ODR o, Z_AttributeList **p, int opt, const char *name)
Definition: z-core.c:316
#define Z_APDU_segmentRequest
Definition: z-core.h:368
#define Z_ElementSpec_externalSpec
Definition: z-core.h:805
int z_AttributeSetId(ODR o, Z_AttributeSetId **p, int opt, const char *name)
Definition: z-core.c:1518
Z_InternationalString Z_ElementSetName
Definition: z-core.h:307
#define Z_Term_oid
Definition: z-core.h:550
int z_ResourceReport(ODR o, Z_ResourceReport **p, int opt, const char *name)
Definition: z-core.c:973
#define odr_explicit_tag(o, t, p, cl, tg, opt, name)
Definition: odr.h:195
#define Z_NamePlusRecord_intermediateFragment
Definition: z-core.h:716
Odr_oid Z_ResourceReportId
Definition: z-core.h:187
ASN.1 Module Z39-50-APDU-1995.
#define Z_DefaultDiagFormat_v3Addinfo
Definition: z-core.h:749
#define Z_Schema_oid
Definition: z-core.h:814
#define Z_Term_general
Definition: z-core.h:547
int z_SearchResponse(ODR o, Z_SearchResponse **p, int opt, const char *name)
Definition: z-core.c:449
int z_ResourceReportResponse(ODR o, Z_ResourceReportResponse **p, int opt, const char *name)
Definition: z-core.c:959
Z_InternationalString Z_ResultSetId
Definition: z-core.h:304
int z_ProxUnit(ODR o, Z_ProxUnit **p, int opt, const char *name)
Definition: z-core.c:444
#define Z_AttributeValue_complex
Definition: z-core.h:587
#define Z_APDU_resourceControlResponse
Definition: z-core.h:360
int z_AccessControlRequest(ODR o, Z_AccessControlRequest **p, int opt, const char *name)
Definition: z-core.c:857
#define Z_NamePlusRecord_startingFragment
Definition: z-core.h:715
#define Z_APDU_searchRequest
Definition: z-core.h:351
#define Z_Query_type_1
Definition: z-core.h:479
#define Z_DuplicateDetectionCriterion_levelOfMatch
Definition: z-core.h:1213
#define Z_OccurrenceByAttributesElem_byDatabase
Definition: z-core.h:1020
#define Z_Query_type_0
Definition: z-core.h:478
int z_ProtocolVersion(ODR o, Z_ProtocolVersion **p, int opt, const char *name)
Definition: z-core.c:164
int z_AttributeElement(ODR o, Z_AttributeElement **p, int opt, const char *name)
Definition: z-core.c:398
#define Z_SortCriterion_leastConmprehensive
Definition: z-core.h:1250
int z_DatabaseSpecificUnit(ODR o, Z_DatabaseSpecificUnit **p, int opt, const char *name)
Definition: z-core.c:685
#define odr_implicit_tag(o, t, p, cl, tg, opt, name)
Definition: odr.h:192
int z_OtherInformation(ODR o, Z_OtherInformation **p, int opt, const char *name)
Definition: z-core.c:1545
int odr_sequence_begin(ODR o, void *p, int size, const char *name)
Definition: odr_seq.c:15
#define Z_DiagRec_defaultFormat
Definition: z-core.h:736
#define Z_DefaultDiagFormat_v2Addinfo
Definition: z-core.h:748
#define Z_ElementSetNames_generic
Definition: z-core.h:773
#define Z_OtherInfo_oid
Definition: z-core.h:1290
int z_ExtendedServicesResponse(ODR o, Z_ExtendedServicesResponse **p, int opt, const char *name)
Definition: z-core.c:1305
int z_RPNQuery(ODR o, Z_RPNQuery **p, int opt, const char *name)
Definition: z-core.c:235
int z_ResourceReportRequest(ODR o, Z_ResourceReportRequest **p, int opt, const char *name)
Definition: z-core.c:945
char * name
Definition: initopt.c:18
int odr_visiblestring(ODR o, char **p, int opt, const char *name)
Definition: odr_use.c:41
int z_ScanRequest(ODR o, Z_ScanRequest **p, int opt, const char *name)
Definition: z-core.c:983
int z_CompSpec(ODR o, Z_CompSpec **p, int opt, const char *name)
Definition: z-core.c:742
int z_ListEntries(ODR o, Z_ListEntries **p, int opt, const char *name)
Definition: z-core.c:1026
#define Z_Operator_or
Definition: z-core.h:566
#define Z_SortKeySpec_abort
Definition: z-core.h:1076
#define Z_APDU_initResponse
Definition: z-core.h:350
#define Z_Operator_prox
Definition: z-core.h:568
int z_SortResponse(ODR o, Z_SortResponse **p, int opt, const char *name)
Definition: z-core.c:1162
#define Z_FragmentSyntax_notExternallyTagged
Definition: z-core.h:727
#define Z_DuplicateDetectionCriterion_caseSensitive
Definition: z-core.h:1214
#define Z_DuplicateDetectionCriterion_rsDuplicates
Definition: z-core.h:1217
int z_NamePlusRecordList(ODR o, Z_NamePlusRecordList **p, int opt, const char *name)
Definition: z-core.c:549
int z_Segment(ODR o, Z_Segment **p, int opt, const char *name)
Definition: z-core.c:518
#define Z_Query_type_101
Definition: z-core.h:482
#define Z_AccessControlRequest_simpleForm
Definition: z-core.h:868
int z_PresentStatus(ODR o, Z_PresentStatus **p, int opt, const char *name)
Definition: z-core.c:725
int z_ElementSpec(ODR o, Z_ElementSpec **p, int opt, const char *name)
Definition: z-core.c:760
int z_ResultSetPlusAttributes(ODR o, Z_ResultSetPlusAttributes **p, int opt, const char *name)
Definition: z-core.c:305
#define Z_OtherInfo_characterInfo
Definition: z-core.h:1287
int z_External(ODR o, Z_External **p, int opt, const char *name)
codec for BER EXTERNAL
Definition: prt-ext.c:95
#define Z_Term_integerAndUnit
Definition: z-core.h:553
#define Z_Term_external
Definition: z-core.h:552
int z_Complex(ODR o, Z_Complex **p, int opt, const char *name)
Definition: z-core.c:245
#define Z_APDU_accessControlResponse
Definition: z-core.h:358
#define Z_Query_type_104
Definition: z-core.h:484
int odr_constructed_begin(ODR o, void *xxp, int zclass, int tag, const char *name)
Definition: odr_cons.c:24
int z_TriggerResourceControlRequest(ODR o, Z_TriggerResourceControlRequest **p, int opt, const char *name)
Definition: z-core.c:929
#define Z_SortKeySpec_missingValueData
Definition: z-core.h:1078
int z_ResultSetId(ODR o, Z_ResultSetId **p, int opt, const char *name)
Definition: z-core.c:1503
#define Z_RecordComp_simple
Definition: z-core.h:645
#define Z_APDU_deleteResultSetResponse
Definition: z-core.h:356
#define Z_RPNStructure_complex
Definition: z-core.h:505
int z_NamePlusRecord(ODR o, Z_NamePlusRecord **p, int opt, const char *name)
Definition: z-core.c:593
int z_Permissions_s(ODR o, Z_Permissions_s **p, int opt, const char *name)
Definition: z-core.c:1322
int z_InitResponse(ODR o, Z_InitResponse **p, int opt, const char *name)
Definition: z-core.c:138
int z_RecordComposition(ODR o, Z_RecordComposition **p, int opt, const char *name)
Definition: z-core.c:473
int z_ElementSetNames(ODR o, Z_ElementSetNames **p, int opt, const char *name)
Definition: z-core.c:707
int odr_initmember(ODR o, void *p, int size)
Definition: odr_tag.c:44
#define Z_StringOrNumeric_numeric
Definition: z-core.h:1324
#define Z_SortElement_databaseSpecific
Definition: z-core.h:1098
int z_SortDbSpecificList_s(ODR o, Z_SortDbSpecificList_s **p, int opt, const char *name)
Definition: z-core.c:1206
int z_DatabaseSpecific(ODR o, Z_DatabaseSpecific **p, int opt, const char *name)
Definition: z-core.c:695
int z_DuplicateDetectionCriterion(ODR o, Z_DuplicateDetectionCriterion **p, int opt, const char *name)
Definition: z-core.c:1397
#define Z_RecordComp_complex
Definition: z-core.h:646
#define Z_NamePlusRecord_databaseRecord
Definition: z-core.h:713
#define Z_OtherInfo_binaryInfo
Definition: z-core.h:1288
int direction
Definition: odr.h:126
#define Z_Records_multipleNSD
Definition: z-core.h:700
int z_AttributesPlusTerm(ODR o, Z_AttributesPlusTerm **p, int opt, const char *name)
Definition: z-core.c:294
#define Z_SortCriterion_oldest
Definition: z-core.h:1252
#define Z_Term_numeric
Definition: z-core.h:548
#define Z_FragmentSyntax_externallyTagged
Definition: z-core.h:726
Definition: z-core.h:536
int odr_integer(ODR o, Odr_int **p, int opt, const char *name)
Definition: odr_int.c:19
int odr_bool(ODR o, Odr_bool **p, int opt, const char *name)
Definition: odr_bool.c:21
int z_SortAttributes(ODR o, Z_SortAttributes **p, int opt, const char *name)
Definition: z-core.c:1246
#define Z_IdAuthentication_anonymous
Definition: z-core.h:406
#define Z_APDU_deleteResultSetRequest
Definition: z-core.h:355
int z_DeleteResultSetResponse(ODR o, Z_DeleteResultSetResponse **p, int opt, const char *name)
Definition: z-core.c:810
int z_Permissions(ODR o, Z_Permissions **p, int opt, const char *name)
Definition: z-core.c:1335
int z_SortCriterionPreferredDatabases(ODR o, Z_SortCriterionPreferredDatabases **p, int opt, const char *name)
Definition: z-core.c:1443
int z_Range(ODR o, Z_Range **p, int opt, const char *name)
Definition: z-core.c:673
int odr_choice(ODR o, Odr_arm arm[], void *p, void *whichp, const char *name)
Definition: odr_choice.c:17
#define Z_SortKey_sortAttributes
Definition: z-core.h:1115
#define Z_RetentionCriterion_percentOfEntries
Definition: z-core.h:1229
int z_DbSpecific(ODR o, Z_DbSpecific **p, int opt, const char *name)
Definition: z-core.c:730
int odr_generalstring(ODR o, char **p, int opt, const char *name)
Definition: odr_use.c:51
int z_ElementSetName(ODR o, Z_ElementSetName **p, int opt, const char *name)
Definition: z-core.c:1508
int z_CloseReason(ODR o, Z_CloseReason **p, int opt, const char *name)
Definition: z-core.c:1364
int z_DeleteStatus(ODR o, Z_DeleteStatus **p, int opt, const char *name)
Definition: z-core.c:852
#define Z_Records_NSD
Definition: z-core.h:699
#define Z_StringOrNumeric_string
Definition: z-core.h:1323
int z_ListStatuses(ODR o, Z_ListStatuses **p, int opt, const char *name)
Definition: z-core.c:840
Odr_int Z_ProxUnit
Definition: z-core.h:82
int z_DuplicateDetectionRequest(ODR o, Z_DuplicateDetectionRequest **p, int opt, const char *name)
Definition: z-core.c:1369
int z_ResourceReportId(ODR o, Z_ResourceReportId **p, int opt, const char *name)
Definition: z-core.c:978
#define Z_SortKeySpec_null
Definition: z-core.h:1077
#define Z_Query_type_100
Definition: z-core.h:481
#define Z_APDU_resourceReportResponse
Definition: z-core.h:363
#define ODR_EXPLICIT
Definition: odr.h:60
#define Z_DuplicateDetectionCriterion_punctuationSensitive
Definition: z-core.h:1215
#define Z_DuplicateDetectionCriterion_regularExpression
Definition: z-core.h:1216
#define Z_APDU_extendedServicesRequest
Definition: z-core.h:369
#define Z_Operand_resultSetId
Definition: z-core.h:516
int odr_sequence_of(ODR o, Odr_fun type, void *p, int *num, const char *name)
Definition: odr_seq.c:134
int z_RetentionCriterion(ODR o, Z_RetentionCriterion **p, int opt, const char *name)
Definition: z-core.c:1421
int(* Odr_fun)(ODR, char **, int, const char *)
Definition: odr.h:135
#define Z_Entry_surrogateDiagnostic
Definition: z-core.h:987
int z_byDatabaseList(ODR o, Z_byDatabaseList **p, int opt, const char *name)
Definition: z-core.c:1090
int z_DuplicateDetectionResponse(ODR o, Z_DuplicateDetectionResponse **p, int opt, const char *name)
Definition: z-core.c:1481
int z_ReferenceId(ODR o, Z_ReferenceId **p, int opt, const char *name)
Definition: z-core.c:1498
int z_Query(ODR o, Z_Query **p, int opt, const char *name)
Definition: z-core.c:207
Odr_oid Z_AttributeSetId
Definition: z-core.h:283
Definition: z-core.h:981
int which
Definition: odr.h:142
Definition: odr.h:137
Definition: odr.h:99
int z_OccurrenceByAttributes(ODR o, Z_OccurrenceByAttributes **p, int opt, const char *name)
Definition: z-core.c:1121
#define Z_APDU_resourceReportRequest
Definition: z-core.h:362
#define Z_ElementSetNames_databaseSpecific
Definition: z-core.h:774
Z_InternationalString Z_DatabaseName
Definition: z-core.h:310
#define Z_ElementSpec_elementSetName
Definition: z-core.h:804
int z_IdAuthentication(ODR o, Z_IdAuthentication **p, int opt, const char *name)
Definition: z-core.c:116
int z_APDU(ODR o, Z_APDU **p, int opt, const char *name)
Definition: z-core.c:12
int z_SearchRequest(ODR o, Z_SearchRequest **p, int opt, const char *name)
Definition: z-core.c:174
int odr_null(ODR o, Odr_null **p, int opt, const char *name)
Definition: odr_null.c:19
#define Z_SortCriterion_mostRecent
Definition: z-core.h:1251
int z_DiagRec(ODR o, Z_DiagRec **p, int opt, const char *name)
Definition: z-core.c:637
int odr_missing(ODR o, int opt, const char *name)
Definition: odr_util.c:82
#define Z_Operator_and
Definition: z-core.h:565
#define Z_Term_dateTime
Definition: z-core.h:551
#define Z_NamePlusRecord_finalFragment
Definition: z-core.h:717
Odr_int Z_CloseReason
Definition: z-core.h:259
int z_SortRequest(ODR o, Z_SortRequest **p, int opt, const char *name)
Definition: z-core.c:1145
int z_Options(ODR o, Z_Options **p, int opt, const char *name)
Definition: z-core.c:169
Definition: odr.h:124
int z_SortKey(ODR o, Z_SortKey **p, int opt, const char *name)
Definition: z-core.c:1256
int z_DiagRecs(ODR o, Z_DiagRecs **p, int opt, const char *name)
Definition: z-core.c:561
#define Z_Query_type_2
Definition: z-core.h:480
#define Z_APDU_extendedServicesResponse
Definition: z-core.h:370
#define Z_AccessControlResponse_simpleForm
Definition: z-core.h:880
#define Z_Records_DBOSD
Definition: z-core.h:698
Odr_int Z_DeleteStatus
Definition: z-core.h:160
int z_RPNStructure(ODR o, Z_RPNStructure **p, int opt, const char *name)
Definition: z-core.c:256
int z_byDatabaseList_s(ODR o, Z_byDatabaseList_s **p, int opt, const char *name)
Definition: z-core.c:1078
#define Z_APDU_duplicateDetectionResponse
Definition: z-core.h:373
int z_SortKeySpec(ODR o, Z_SortKeySpec **p, int opt, const char *name)
Definition: z-core.c:1181
int odr_sequence_end(ODR o)
Definition: odr_seq.c:61
int z_SortDbSpecificList(ODR o, Z_SortDbSpecificList **p, int opt, const char *name)
Definition: z-core.c:1216
#define Z_Operand_APT
Definition: z-core.h:515
int z_Unit(ODR o, Z_Unit **p, int opt, const char *name)
Definition: z-core.c:1582
#define Z_IdAuthentication_other
Definition: z-core.h:407
#define Z_Term_null
Definition: z-core.h:554
int z_ScanResponse(ODR o, Z_ScanResponse **p, int opt, const char *name)
Definition: z-core.c:1004
int z_InfoCategory(ODR o, Z_InfoCategory **p, int opt, const char *name)
Definition: z-core.c:1558
int opt
Definition: initopt.c:19
int z_Entry(ODR o, Z_Entry **p, int opt, const char *name)
Definition: z-core.c:1040
int z_PresentResponse(ODR o, Z_PresentResponse **p, int opt, const char *name)
Definition: z-core.c:533
int z_Records(ODR o, Z_Records **p, int opt, const char *name)
Definition: z-core.c:573
int z_DefaultDiagFormat(ODR o, Z_DefaultDiagFormat **p, int opt, const char *name)
Definition: z-core.c:655
#define Z_APDU_sortRequest
Definition: z-core.h:366
#define Z_APDU_close
Definition: z-core.h:371
#define ODR_IMPLICIT
Definition: odr.h:59
int odr_oid(ODR o, Odr_oid **p, int opt, const char *name)
Definition: odr_oid.c:20
#define Z_RetentionCriterion_duplicatesOnly
Definition: z-core.h:1230
int z_Specification(ODR o, Z_Specification **p, int opt, const char *name)
Definition: z-core.c:778
#define Z_IdAuthentication_open
Definition: z-core.h:404
#define Z_Term_characterString
Definition: z-core.h:549
#define Z_SortKey_sortField
Definition: z-core.h:1113
#define Z_ProximityOperator_known
Definition: z-core.h:606
structure for all known EXTERNALs
Definition: prt-ext.h:58
#define Z_SortCriterion_preferredDatabases
Definition: z-core.h:1254
#define Z_IdAuthentication_idPass
Definition: z-core.h:405
#define Z_OtherInfo_externallyDefinedInfo
Definition: z-core.h:1289
int z_ListStatus(ODR o, Z_ListStatus **p, int opt, const char *name)
Definition: z-core.c:830
#define Z_SortCriterion_mostComprehensive
Definition: z-core.h:1249
int z_InternationalString(ODR o, Z_InternationalString **p, int opt, const char *name)
Definition: z-core.c:1598
#define Z_APDU_sortResponse
Definition: z-core.h:367
#define Z_AccessControlResponse_externallyDefined
Definition: z-core.h:881
int z_InitRequest(ODR o, Z_InitRequest **p, int opt, const char *name)
Definition: z-core.c:76
int z_TermInfo(ODR o, Z_TermInfo **p, int opt, const char *name)
Definition: z-core.c:1058
#define Z_Operator_and_not
Definition: z-core.h:567
int z_OccurrenceByAttributesElem(ODR o, Z_OccurrenceByAttributesElem **p, int opt, const char *name)
Definition: z-core.c:1102
int z_SortElement(ODR o, Z_SortElement **p, int opt, const char *name)
Definition: z-core.c:1228
int odr_octetstring(ODR o, Odr_oct **p, int opt, const char *name)
Definition: odr_oct.c:19
int z_ExtendedServicesRequest(ODR o, Z_ExtendedServicesRequest **p, int opt, const char *name)
Definition: z-core.c:1276
#define Z_AccessControlRequest_externallyDefined
Definition: z-core.h:869
Definition: z-core.h:321
int z_ResourceControlRequest(ODR o, Z_ResourceControlRequest **p, int opt, const char *name)
Definition: z-core.c:895
int z_ProximityOperator(ODR o, Z_ProximityOperator **p, int opt, const char *name)
Definition: z-core.c:418
int z_FragmentSyntax(ODR o, Z_FragmentSyntax **p, int opt, const char *name)
Definition: z-core.c:619
#define Z_Schema_uri
Definition: z-core.h:815
int odr_bitstring(ODR o, Odr_bitmask **p, int opt, const char *name)
Definition: odr_bit.c:22
#define Z_RetentionCriterion_numberOfEntries
Definition: z-core.h:1228
int z_Term(ODR o, Z_Term **p, int opt, const char *name)
Definition: z-core.c:329
#define Z_RetentionCriterion_discardRsDuplicates
Definition: z-core.h:1231
#define Z_RPNStructure_simple
Definition: z-core.h:504
int odr_generalizedtime(ODR o, char **p, int opt, const char *name)
Definition: odr_use.c:63
#define Z_APDU_resourceControlRequest
Definition: z-core.h:359
int z_ANY_type_0(ODR o, void **p, int opt)
Definition: z-core.c:1623
#define Z_ProximityOperator_private
Definition: z-core.h:607
int z_Operand(ODR o, Z_Operand **p, int opt, const char *name)
Definition: z-core.c:274
#define Z_APDU_triggerResourceControlRequest
Definition: z-core.h:361
#define Z_OccurrenceByAttributesElem_global
Definition: z-core.h:1019
#define Z_APDU_scanRequest
Definition: z-core.h:364
int z_SortKeySpecList(ODR o, Z_SortKeySpecList **p, int opt, const char *name)
Definition: z-core.c:1133
int odr_constructed_end(ODR o)
Definition: odr_cons.c:148
#define Z_NamePlusRecord_surrogateDiagnostic
Definition: z-core.h:714
#define ODR_CONTEXT
Definition: odr.h:67
int z_IntUnit(ODR o, Z_IntUnit **p, int opt, const char *name)
Definition: z-core.c:1570
#define Z_APDU_accessControlRequest
Definition: z-core.h:357
#define Z_DiagRec_externallyDefined
Definition: z-core.h:737
#define Z_APDU_initRequest
Definition: z-core.h:349
#define Z_Operand_resultAttr
Definition: z-core.h:517
#define Z_Query_type_102
Definition: z-core.h:483
#define Z_APDU_duplicateDetectionRequest
Definition: z-core.h:372
int z_ComplexAttribute(ODR o, Z_ComplexAttribute **p, int opt, const char *name)
Definition: z-core.c:384
int z_Close(ODR o, Z_Close **p, int opt, const char *name)
Definition: z-core.c:1347
int z_PresentRequest(ODR o, Z_PresentRequest **p, int opt, const char *name)
Definition: z-core.c:491
#define Z_APDU_presentResponse
Definition: z-core.h:354
int z_SortCriterion(ODR o, Z_SortCriterion **p, int opt, const char *name)
Definition: z-core.c:1455
#define Z_SortElement_generic
Definition: z-core.h:1097
int z_DeleteResultSetRequest(ODR o, Z_DeleteResultSetRequest **p, int opt, const char *name)
Definition: z-core.c:796
#define ODR_DECODE
Definition: odr.h:95
#define Z_Entry_termInfo
Definition: z-core.h:986
int z_DatabaseName(ODR o, Z_DatabaseName **p, int opt, const char *name)
Definition: z-core.c:1513
int odr_implicit_settag(ODR o, int zclass, int tag)
Definition: odr_tag.c:32
#define Z_SortKey_elementSpec
Definition: z-core.h:1114
int z_ResourceControlResponse(ODR o, Z_ResourceControlResponse **p, int opt, const char *name)
Definition: z-core.c:915
int z_OtherInformationUnit(ODR o, Z_OtherInformationUnit **p, int opt, const char *name)
Definition: z-core.c:1523
#define Z_SortCriterion_leastCost
Definition: z-core.h:1253
#define Z_APDU_presentRequest
Definition: z-core.h:353