1 | /* Generated automatically by the YAZ ASN.1 Compiler 0.3 */
|
---|
2 | /* Module-C: ESFormat-ExportInvocation */
|
---|
3 |
|
---|
4 | #include <yaz/zes-expi.h>
|
---|
5 |
|
---|
6 | int z_EIExportInvocationEsRequest (ODR o, Z_EIExportInvocationEsRequest **p, int opt, const char *name)
|
---|
7 | {
|
---|
8 | if (!odr_sequence_begin (o, p, sizeof(**p), name))
|
---|
9 | return opt && odr_ok (o);
|
---|
10 | return
|
---|
11 | odr_explicit_tag (o, z_EIOriginPartToKeep,
|
---|
12 | &(*p)->toKeep, ODR_CONTEXT, 1, 0, "toKeep") &&
|
---|
13 | odr_explicit_tag (o, z_EIOriginPartNotToKeep,
|
---|
14 | &(*p)->notToKeep, ODR_CONTEXT, 2, 0, "notToKeep") &&
|
---|
15 | odr_sequence_end (o);
|
---|
16 | }
|
---|
17 |
|
---|
18 | int z_EIExportInvocationTaskPackage (ODR o, Z_EIExportInvocationTaskPackage **p, int opt, const char *name)
|
---|
19 | {
|
---|
20 | if (!odr_sequence_begin (o, p, sizeof(**p), name))
|
---|
21 | return opt && odr_ok (o);
|
---|
22 | return
|
---|
23 | odr_explicit_tag (o, z_EIOriginPartToKeep,
|
---|
24 | &(*p)->originPart, ODR_CONTEXT, 1, 0, "originPart") &&
|
---|
25 | odr_explicit_tag (o, z_EITargetPart,
|
---|
26 | &(*p)->targetPart, ODR_CONTEXT, 2, 1, "targetPart") &&
|
---|
27 | odr_sequence_end (o);
|
---|
28 | }
|
---|
29 |
|
---|
30 | int z_EIExportInvocation (ODR o, Z_EIExportInvocation **p, int opt, const char *name)
|
---|
31 | {
|
---|
32 | static Odr_arm arm[] = {
|
---|
33 | {ODR_IMPLICIT, ODR_CONTEXT, 1, Z_EIExportInvocation_esRequest,
|
---|
34 | (Odr_fun) z_EIExportInvocationEsRequest, "esRequest"},
|
---|
35 | {ODR_IMPLICIT, ODR_CONTEXT, 2, Z_EIExportInvocation_taskPackage,
|
---|
36 | (Odr_fun) z_EIExportInvocationTaskPackage, "taskPackage"},
|
---|
37 | {-1, -1, -1, -1, (Odr_fun) 0, 0}
|
---|
38 | };
|
---|
39 | if (!odr_initmember(o, p, sizeof(**p)))
|
---|
40 | return opt && odr_ok(o);
|
---|
41 | if (odr_choice(o, arm, &(*p)->u, &(*p)->which, name))
|
---|
42 | return 1;
|
---|
43 | *p = 0;
|
---|
44 | return opt && odr_ok(o);
|
---|
45 | }
|
---|
46 |
|
---|
47 | int z_EIOriginPartToKeep (ODR o, Z_EIOriginPartToKeep **p, int opt, const char *name)
|
---|
48 | {
|
---|
49 | static Odr_arm arm[] = {
|
---|
50 | {ODR_IMPLICIT, ODR_CONTEXT, 1, Z_EIOriginPartToKeep_packageName,
|
---|
51 | (Odr_fun) z_InternationalString, "packageName"},
|
---|
52 | {ODR_EXPLICIT, ODR_CONTEXT, 2, Z_EIOriginPartToKeep_packageSpec,
|
---|
53 | (Odr_fun) z_ESExportSpecification, "packageSpec"},
|
---|
54 | {-1, -1, -1, -1, (Odr_fun) 0, 0}
|
---|
55 | };
|
---|
56 | if (!odr_sequence_begin (o, p, sizeof(**p), name))
|
---|
57 | return opt && odr_ok (o);
|
---|
58 | return
|
---|
59 | odr_constructed_begin (o, &(*p)->u, ODR_CONTEXT, 1, "exportSpec") &&
|
---|
60 | odr_choice (o, arm, &(*p)->u, &(*p)->which, 0) &&
|
---|
61 | odr_constructed_end (o) &&
|
---|
62 | odr_implicit_tag (o, odr_integer,
|
---|
63 | &(*p)->numberOfCopies, ODR_CONTEXT, 2, 0, "numberOfCopies") &&
|
---|
64 | odr_sequence_end (o);
|
---|
65 | }
|
---|
66 |
|
---|
67 | int z_EIOriginPartNotToKeepRanges_s (ODR o, Z_EIOriginPartNotToKeepRanges_s **p, int opt, const char *name)
|
---|
68 | {
|
---|
69 | if (!odr_sequence_begin (o, p, sizeof(**p), name))
|
---|
70 | return opt && odr_ok (o);
|
---|
71 | return
|
---|
72 | odr_implicit_tag (o, odr_integer,
|
---|
73 | &(*p)->start, ODR_CONTEXT, 1, 0, "start") &&
|
---|
74 | odr_implicit_tag (o, odr_integer,
|
---|
75 | &(*p)->count, ODR_CONTEXT, 2, 1, "count") &&
|
---|
76 | odr_sequence_end (o);
|
---|
77 | }
|
---|
78 |
|
---|
79 | int z_EIOriginPartNotToKeepRanges (ODR o, Z_EIOriginPartNotToKeepRanges **p, int opt, const char *name)
|
---|
80 | {
|
---|
81 | if (!odr_initmember (o, p, sizeof(**p)))
|
---|
82 | return opt && odr_ok(o);
|
---|
83 | if (odr_sequence_of (o, (Odr_fun) z_EIOriginPartNotToKeepRanges_s, &(*p)->elements,
|
---|
84 | &(*p)->num, name))
|
---|
85 | return 1;
|
---|
86 | *p = 0;
|
---|
87 | return opt && odr_ok(o);
|
---|
88 | }
|
---|
89 |
|
---|
90 | int z_EIOriginPartNotToKeep (ODR o, Z_EIOriginPartNotToKeep **p, int opt, const char *name)
|
---|
91 | {
|
---|
92 | static Odr_arm arm[] = {
|
---|
93 | {ODR_IMPLICIT, ODR_CONTEXT, 1, Z_EIOriginPartNotToKeep_all,
|
---|
94 | (Odr_fun) odr_null, "all"},
|
---|
95 | {ODR_IMPLICIT, ODR_CONTEXT, 2, Z_EIOriginPartNotToKeep_ranges,
|
---|
96 | (Odr_fun) z_EIOriginPartNotToKeepRanges, "ranges"},
|
---|
97 | {-1, -1, -1, -1, (Odr_fun) 0, 0}
|
---|
98 | };
|
---|
99 | if (!odr_sequence_begin (o, p, sizeof(**p), name))
|
---|
100 | return opt && odr_ok (o);
|
---|
101 | return
|
---|
102 | odr_implicit_tag (o, z_InternationalString,
|
---|
103 | &(*p)->resultSetId, ODR_CONTEXT, 1, 0, "resultSetId") &&
|
---|
104 | odr_constructed_begin (o, &(*p)->u, ODR_CONTEXT, 2, "records") &&
|
---|
105 | odr_choice (o, arm, &(*p)->u, &(*p)->which, 0) &&
|
---|
106 | odr_constructed_end (o) &&
|
---|
107 | odr_sequence_end (o);
|
---|
108 | }
|
---|
109 |
|
---|
110 | int z_EITargetPart (ODR o, Z_EITargetPart **p, int opt, const char *name)
|
---|
111 | {
|
---|
112 | if (!odr_sequence_begin (o, p, sizeof(**p), name))
|
---|
113 | return opt && odr_ok (o);
|
---|
114 | return
|
---|
115 | odr_implicit_tag (o, z_IntUnit,
|
---|
116 | &(*p)->estimatedQuantity, ODR_CONTEXT, 1, 1, "estimatedQuantity") &&
|
---|
117 | odr_implicit_tag (o, z_IntUnit,
|
---|
118 | &(*p)->quantitySoFar, ODR_CONTEXT, 2, 1, "quantitySoFar") &&
|
---|
119 | odr_implicit_tag (o, z_IntUnit,
|
---|
120 | &(*p)->estimatedCost, ODR_CONTEXT, 3, 1, "estimatedCost") &&
|
---|
121 | odr_implicit_tag (o, z_IntUnit,
|
---|
122 | &(*p)->costSoFar, ODR_CONTEXT, 4, 1, "costSoFar") &&
|
---|
123 | odr_sequence_end (o);
|
---|
124 | }
|
---|