Moving in e2sim originally from it/test/simulators
[sim/e2-interface.git] / e2sim / ASN1c / OPEN_TYPE.h
1 /*****************************************************************************
2 #                                                                            *
3 # Copyright 2019 AT&T Intellectual Property                                  *
4 #                                                                            *
5 # Licensed under the Apache License, Version 2.0 (the "License");            *
6 # you may not use this file except in compliance with the License.           *
7 # You may obtain a copy of the License at                                    *
8 #                                                                            *
9 #      http://www.apache.org/licenses/LICENSE-2.0                            *
10 #                                                                            *
11 # Unless required by applicable law or agreed to in writing, software        *
12 # distributed under the License is distributed on an "AS IS" BASIS,          *
13 # WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.   *
14 # See the License for the specific language governing permissions and        *
15 # limitations under the License.                                             *
16 #                                                                            *
17 ******************************************************************************/
18
19 /*-
20  * Copyright (c) 2017-2017 Lev Walkin <vlm@lionet.info>. All rights reserved.
21  * Redistribution and modifications are permitted subject to BSD license.
22  */
23 #ifndef ASN_OPEN_TYPE_H
24 #define ASN_OPEN_TYPE_H
25
26 #include <asn_application.h>
27
28 #ifdef __cplusplus
29 extern "C" {
30 #endif
31
32 #define OPEN_TYPE_free CHOICE_free
33 #define OPEN_TYPE_print CHOICE_print
34 #define OPEN_TYPE_compare CHOICE_compare
35 #define OPEN_TYPE_constraint CHOICE_constraint
36 #define OPEN_TYPE_decode_ber NULL
37 #define OPEN_TYPE_encode_der CHOICE_encode_der
38 #define OPEN_TYPE_decode_xer NULL
39 #define OPEN_TYPE_encode_xer CHOICE_encode_xer
40 #define OPEN_TYPE_decode_oer NULL
41 #define OPEN_TYPE_encode_oer CHOICE_encode_oer
42 #define OPEN_TYPE_decode_uper NULL
43 #define OPEN_TYPE_decode_aper NULL
44
45 extern asn_TYPE_operation_t asn_OP_OPEN_TYPE;
46
47 /*
48  * Decode an Open Type which is potentially constraiend
49  * by the other members of the parent structure.
50  */
51 asn_dec_rval_t OPEN_TYPE_ber_get(const asn_codec_ctx_t *opt_codec_ctx,
52                                  const asn_TYPE_descriptor_t *parent_type,
53                                  void *parent_structure,
54                                  const asn_TYPE_member_t *element,
55                                  const void *ptr, size_t size);
56
57 asn_dec_rval_t OPEN_TYPE_xer_get(const asn_codec_ctx_t *opt_codec_ctx,
58                                  const asn_TYPE_descriptor_t *parent_type,
59                                  void *parent_structure,
60                                  const asn_TYPE_member_t *element,
61                                  const void *ptr, size_t size);
62
63 asn_dec_rval_t OPEN_TYPE_oer_get(const asn_codec_ctx_t *opt_codec_ctx,
64                                  const asn_TYPE_descriptor_t *parent_type,
65                                  void *parent_structure,
66                                  asn_TYPE_member_t *element, const void *ptr,
67                                  size_t size);
68
69 asn_dec_rval_t OPEN_TYPE_uper_get(const asn_codec_ctx_t *opt_codec_ctx,
70                                   const asn_TYPE_descriptor_t *parent_type,
71                                   void *parent_structure,
72                                   const asn_TYPE_member_t *element,
73                                   asn_per_data_t *pd);
74
75 asn_dec_rval_t OPEN_TYPE_aper_get(const asn_codec_ctx_t *opt_codec_ctx,
76                                   const asn_TYPE_descriptor_t *parent_type,
77                                   void *parent_structure,
78                                   const asn_TYPE_member_t *element,
79                                   asn_per_data_t *pd);
80
81 asn_enc_rval_t OPEN_TYPE_encode_uper(
82     const asn_TYPE_descriptor_t *type_descriptor,
83     const asn_per_constraints_t *constraints, const void *struct_ptr,
84     asn_per_outp_t *per_output);
85
86 asn_enc_rval_t OPEN_TYPE_encode_aper(
87     const asn_TYPE_descriptor_t *type_descriptor,
88     const asn_per_constraints_t *constraints, const void *struct_ptr,
89     asn_per_outp_t *per_output);
90
91 #ifdef __cplusplus
92 }
93 #endif
94
95 #endif  /* ASN_OPEN_TYPE_H */