blob: ec4dd88db00a8b4f6456d79501909057fb4d849f [file] [log] [blame]
Lev Walkinf15320b2004-06-03 03:38:44 +00001/*-
2 * Copyright (c) 2004 Lev Walkin <vlm@lionet.info>. All rights reserved.
3 * Redistribution and modifications are permitted subject to BSD license.
4 */
5/*
6 * Please read the NativeInteger.h for the explanation wrt. differences between
7 * INTEGER and NativeInteger.
8 * Basically, both are decoders and encoders of ASN.1 INTEGER type, but this
9 * implementation deals with the standard (machine-specific) representation
10 * of them instead of using the platform-independent buffer.
11 */
Lev Walkina9cc46e2004-09-22 16:06:28 +000012#include <asn_internal.h>
Lev Walkinf15320b2004-06-03 03:38:44 +000013#include <NativeEnumerated.h>
14
15/*
16 * NativeEnumerated basic type description.
17 */
18static ber_tlv_tag_t asn1_DEF_NativeEnumerated_tags[] = {
19 (ASN_TAG_CLASS_UNIVERSAL | (10 << 2))
20};
21asn1_TYPE_descriptor_t asn1_DEF_NativeEnumerated = {
22 "ENUMERATED", /* The ASN.1 type is still ENUMERATED */
Lev Walkina9cc46e2004-09-22 16:06:28 +000023 NativeInteger_free,
24 NativeInteger_print,
Lev Walkinf15320b2004-06-03 03:38:44 +000025 asn_generic_no_constraint,
26 NativeInteger_decode_ber,
27 NativeInteger_encode_der,
Lev Walkina9cc46e2004-09-22 16:06:28 +000028 0, /* Not implemented yet */
29 NativeInteger_encode_xer,
Lev Walkinf15320b2004-06-03 03:38:44 +000030 0, /* Use generic outmost tag fetcher */
31 asn1_DEF_NativeEnumerated_tags,
Lev Walkin188ed2c2004-09-13 08:31:01 +000032 sizeof(asn1_DEF_NativeEnumerated_tags) / sizeof(asn1_DEF_NativeEnumerated_tags[0]),
33 asn1_DEF_NativeEnumerated_tags, /* Same as above */
34 sizeof(asn1_DEF_NativeEnumerated_tags) / sizeof(asn1_DEF_NativeEnumerated_tags[0]),
Lev Walkind9bd7752004-06-05 08:17:50 +000035 0, /* Always in primitive form */
Lev Walkin449f8322004-08-20 13:23:42 +000036 0, 0, /* No members */
Lev Walkind9bd7752004-06-05 08:17:50 +000037 0 /* No specifics */
Lev Walkinf15320b2004-06-03 03:38:44 +000038};
Lev Walkin449f8322004-08-20 13:23:42 +000039