ITS
INTEGER.c File Reference
#include <asn_internal.h>
#include <INTEGER.h>
#include <asn_codecs_prim.h>
#include <errno.h>
Include dependency graph for INTEGER.c:

Go to the source code of this file.

Classes

struct  e2v_key
 

Functions

asn_enc_rval_t INTEGER_encode_der (asn_TYPE_descriptor_t *td, void *sptr, int tag_mode, ber_tlv_tag_t tag, asn_app_consume_bytes_f *cb, void *app_key)
 
static const asn_INTEGER_enum_map_tINTEGER_map_enum2value (asn_INTEGER_specifics_t *specs, const char *lstart, const char *lstop)
 
static ssize_t INTEGER__dump (asn_TYPE_descriptor_t *td, const INTEGER_t *st, asn_app_consume_bytes_f *cb, void *app_key, int plainOrXER)
 
int INTEGER_print (asn_TYPE_descriptor_t *td, const void *sptr, int ilevel, asn_app_consume_bytes_f *cb, void *app_key)
 
static int INTEGER__compar_enum2value (const void *kp, const void *am)
 
static int INTEGER__compar_value2enum (const void *kp, const void *am)
 
const asn_INTEGER_enum_map_tINTEGER_map_value2enum (asn_INTEGER_specifics_t *specs, long value)
 
static int INTEGER_st_prealloc (INTEGER_t *st, int min_size)
 
static enum xer_pbd_rval INTEGER__xer_body_decode (asn_TYPE_descriptor_t *td, void *sptr, const void *chunk_buf, size_t chunk_size)
 
asn_dec_rval_t INTEGER_decode_xer (asn_codec_ctx_t *opt_codec_ctx, asn_TYPE_descriptor_t *td, void **sptr, const char *opt_mname, const void *buf_ptr, size_t size)
 
asn_enc_rval_t INTEGER_encode_xer (asn_TYPE_descriptor_t *td, void *sptr, int ilevel, enum xer_encoder_flags_e flags, asn_app_consume_bytes_f *cb, void *app_key)
 
asn_dec_rval_t INTEGER_decode_uper (asn_codec_ctx_t *opt_codec_ctx, asn_TYPE_descriptor_t *td, asn_per_constraints_t *constraints, void **sptr, asn_per_data_t *pd)
 
asn_enc_rval_t INTEGER_encode_uper (asn_TYPE_descriptor_t *td, asn_per_constraints_t *constraints, void *sptr, asn_per_outp_t *po)
 
int asn_INTEGER2long (const INTEGER_t *iptr, long *lptr)
 
int asn_INTEGER2ulong (const INTEGER_t *iptr, unsigned long *lptr)
 
int asn_ulong2INTEGER (INTEGER_t *st, unsigned long value)
 
int asn_long2INTEGER (INTEGER_t *st, long value)
 
enum asn_strtol_result_e asn_strtol (const char *str, const char *end, long *lp)
 
enum asn_strtol_result_e asn_strtol_lim (const char *str, const char **end, long *lp)
 

Variables

static ber_tlv_tag_t asn_DEF_INTEGER_tags []
 
asn_TYPE_descriptor_t asn_DEF_INTEGER
 

Function Documentation

◆ asn_INTEGER2long()

int asn_INTEGER2long ( const INTEGER_t iptr,
long *  lptr 
)

Definition at line 765 of file INTEGER.c.

References ASN__PRIMITIVE_TYPE_s::buf, and ASN__PRIMITIVE_TYPE_s::size.

Referenced by constr_INTEGER(), cpy_INTEGER(), INTEGER__dump(), INTEGER_encode_uper(), isEqual_INTEGER(), make_ManagementContainer(), NativeInteger_decode_ber(), NativeInteger_decode_uper(), NativeInteger_decode_xer(), and TimestampIts_constraint().

Here is the caller graph for this function:

◆ asn_INTEGER2ulong()

◆ asn_long2INTEGER()

◆ asn_strtol()

enum asn_strtol_result_e asn_strtol ( const char *  str,
const char *  end,
long *  lp 
)

Definition at line 940 of file INTEGER.c.

References ASN_STRTOL_ERROR_INVAL, ASN_STRTOL_ERROR_RANGE, ASN_STRTOL_EXPECT_MORE, ASN_STRTOL_EXTRA_DATA, asn_strtol_lim(), and ASN_STRTOL_OK.

Here is the call graph for this function:

◆ asn_strtol_lim()

enum asn_strtol_result_e asn_strtol_lim ( const char *  str,
const char **  end,
long *  lp 
)

Definition at line 966 of file INTEGER.c.

References ASN_STRTOL_ERROR_INVAL, ASN_STRTOL_ERROR_RANGE, ASN_STRTOL_EXPECT_MORE, ASN_STRTOL_EXTRA_DATA, and ASN_STRTOL_OK.

Referenced by asn_strtol(), and INTEGER__xer_body_decode().

Here is the caller graph for this function:

◆ asn_ulong2INTEGER()

int asn_ulong2INTEGER ( INTEGER_t st,
unsigned long  value 
)

Definition at line 857 of file INTEGER.c.

References asn_long2INTEGER(), ASN__PRIMITIVE_TYPE_s::buf, FREEMEM, MALLOC, and ASN__PRIMITIVE_TYPE_s::size.

Referenced by fill_ManagementContainer(), NativeInteger_encode_uper(), denMessageTable::setTimestamp(), and denMessageTableSource::setTimestamp().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ INTEGER__compar_enum2value()

static int INTEGER__compar_enum2value ( const void *  kp,
const void *  am 
)
static

Definition at line 215 of file INTEGER.c.

References asn_INTEGER_enum_map_s::enum_name, e2v_key::evmap, e2v_key::start, e2v_key::stop, and e2v_key::vemap.

Referenced by INTEGER_map_enum2value().

Here is the caller graph for this function:

◆ INTEGER__compar_value2enum()

static int INTEGER__compar_value2enum ( const void *  kp,
const void *  am 
)
static

Definition at line 272 of file INTEGER.c.

References asn_INTEGER_enum_map_s::nat_value.

Referenced by INTEGER_map_value2enum().

Here is the caller graph for this function:

◆ INTEGER__dump()

static ssize_t INTEGER__dump ( asn_TYPE_descriptor_t td,
const INTEGER_t st,
asn_app_consume_bytes_f cb,
void *  app_key,
int  plainOrXER 
)
static

Definition at line 109 of file INTEGER.c.

References ASN_DEBUG(), asn_INTEGER2long(), asn_INTEGER2ulong(), ASN__PRIMITIVE_TYPE_s::buf, asn_INTEGER_enum_map_s::enum_len, asn_INTEGER_enum_map_s::enum_name, asn_INTEGER_specifics_s::field_unsigned, INTEGER_map_value2enum(), ASN__PRIMITIVE_TYPE_s::size, asn_TYPE_descriptor_s::specifics, and asn_INTEGER_specifics_s::strict_enumeration.

Referenced by INTEGER_encode_xer(), and INTEGER_print().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ INTEGER__xer_body_decode()

static enum xer_pbd_rval INTEGER__xer_body_decode ( asn_TYPE_descriptor_t td,
void *  sptr,
const void *  chunk_buf,
size_t  chunk_size 
)
static

Definition at line 308 of file INTEGER.c.

References ASN_DEBUG(), asn_long2INTEGER(), ASN_STRTOL_ERROR_INVAL, ASN_STRTOL_ERROR_RANGE, ASN_STRTOL_EXPECT_MORE, ASN_STRTOL_EXTRA_DATA, asn_strtol_lim(), ASN_STRTOL_OK, ASN__PRIMITIVE_TYPE_s::buf, asn_INTEGER_enum_map_s::enum_name, INTEGER_map_enum2value(), INTEGER_st_prealloc(), asn_INTEGER_enum_map_s::nat_value, ASN__PRIMITIVE_TYPE_s::size, asn_TYPE_descriptor_s::specifics, XPBD_BODY_CONSUMED, XPBD_BROKEN_ENCODING, XPBD_DECODER_LIMIT, XPBD_NOT_BODY_IGNORE, and XPBD_SYSTEM_FAILURE.

Referenced by INTEGER_decode_xer().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ INTEGER_decode_uper()

asn_dec_rval_t INTEGER_decode_uper ( asn_codec_ctx_t opt_codec_ctx,
asn_TYPE_descriptor_t td,
asn_per_constraints_t constraints,
void **  sptr,
asn_per_data_t pd 
)

Definition at line 558 of file INTEGER.c.

References RC_OK, and asn_TYPE_descriptor_s::specifics.

◆ INTEGER_decode_xer()

asn_dec_rval_t INTEGER_decode_xer ( asn_codec_ctx_t opt_codec_ctx,
asn_TYPE_descriptor_t td,
void **  sptr,
const char *  opt_mname,
const void *  buf_ptr,
size_t  size 
)

Definition at line 527 of file INTEGER.c.

References INTEGER__xer_body_decode(), and xer_decode_primitive().

Here is the call graph for this function:

◆ INTEGER_encode_der()

asn_enc_rval_t INTEGER_encode_der ( asn_TYPE_descriptor_t td,
void *  sptr,
int  tag_mode,
ber_tlv_tag_t  tag,
asn_app_consume_bytes_f cb,
void *  app_key 
)

Definition at line 48 of file INTEGER.c.

References ASN_DEBUG(), ASN__PRIMITIVE_TYPE_s::buf, der_encode_primitive, asn_TYPE_descriptor_s::name, and ASN__PRIMITIVE_TYPE_s::size.

Here is the call graph for this function:

◆ INTEGER_encode_uper()

◆ INTEGER_encode_xer()

asn_enc_rval_t INTEGER_encode_xer ( asn_TYPE_descriptor_t td,
void *  sptr,
int  ilevel,
enum xer_encoder_flags_e  flags,
asn_app_consume_bytes_f cb,
void *  app_key 
)

Definition at line 537 of file INTEGER.c.

References _ASN_ENCODE_FAILED, _ASN_ENCODED_OK, ASN__PRIMITIVE_TYPE_s::buf, asn_enc_rval_s::encoded, and INTEGER__dump().

Here is the call graph for this function:

◆ INTEGER_map_enum2value()

static const asn_INTEGER_enum_map_t * INTEGER_map_enum2value ( asn_INTEGER_specifics_t specs,
const char *  lstart,
const char *  lstop 
)
static

Definition at line 234 of file INTEGER.c.

References asn_INTEGER_specifics_s::enum2value, e2v_key::evmap, INTEGER__compar_enum2value(), asn_INTEGER_specifics_s::map_count, e2v_key::start, e2v_key::stop, asn_INTEGER_specifics_s::value2enum, and e2v_key::vemap.

Referenced by INTEGER__xer_body_decode().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ INTEGER_map_value2enum()

const asn_INTEGER_enum_map_t* INTEGER_map_value2enum ( asn_INTEGER_specifics_t specs,
long  value 
)

Definition at line 282 of file INTEGER.c.

References INTEGER__compar_value2enum(), asn_INTEGER_specifics_s::map_count, and asn_INTEGER_specifics_s::value2enum.

Referenced by INTEGER__dump(), and NativeEnumerated_encode_xer().

Here is the call graph for this function:
Here is the caller graph for this function:

◆ INTEGER_print()

int INTEGER_print ( asn_TYPE_descriptor_t td,
const void *  sptr,
int  ilevel,
asn_app_consume_bytes_f cb,
void *  app_key 
)

Definition at line 192 of file INTEGER.c.

References ASN__PRIMITIVE_TYPE_s::buf, and INTEGER__dump().

Here is the call graph for this function:

◆ INTEGER_st_prealloc()

static int INTEGER_st_prealloc ( INTEGER_t st,
int  min_size 
)
static

Definition at line 291 of file INTEGER.c.

References ASN__PRIMITIVE_TYPE_s::buf, FREEMEM, MALLOC, and ASN__PRIMITIVE_TYPE_s::size.

Referenced by INTEGER__xer_body_decode().

Here is the caller graph for this function:

Variable Documentation

◆ asn_DEF_INTEGER

asn_TYPE_descriptor_t asn_DEF_INTEGER
Initial value:
= {
"INTEGER",
"INTEGER",
0,
0,
0, 0,
0
}
asn_constr_check_f asn_generic_no_constraint
Definition: constraints.h:51
asn_dec_rval_t INTEGER_decode_uper(asn_codec_ctx_t *opt_codec_ctx, asn_TYPE_descriptor_t *td, asn_per_constraints_t *constraints, void **sptr, asn_per_data_t *pd)
Definition: INTEGER.c:558
asn_enc_rval_t INTEGER_encode_uper(asn_TYPE_descriptor_t *td, asn_per_constraints_t *constraints, void *sptr, asn_per_outp_t *po)
Definition: INTEGER.c:669
int INTEGER_print(asn_TYPE_descriptor_t *td, const void *sptr, int ilevel, asn_app_consume_bytes_f *cb, void *app_key)
Definition: INTEGER.c:192
static ber_tlv_tag_t asn_DEF_INTEGER_tags[]
Definition: INTEGER.c:14
asn_enc_rval_t INTEGER_encode_der(asn_TYPE_descriptor_t *td, void *sptr, int tag_mode, ber_tlv_tag_t tag, asn_app_consume_bytes_f *cb, void *app_key)
Definition: INTEGER.c:48
asn_enc_rval_t INTEGER_encode_xer(asn_TYPE_descriptor_t *td, void *sptr, int ilevel, enum xer_encoder_flags_e flags, asn_app_consume_bytes_f *cb, void *app_key)
Definition: INTEGER.c:537
asn_dec_rval_t INTEGER_decode_xer(asn_codec_ctx_t *opt_codec_ctx, asn_TYPE_descriptor_t *td, void **sptr, const char *opt_mname, const void *buf_ptr, size_t size)
Definition: INTEGER.c:527
ber_type_decoder_f ber_decode_primitive
asn_struct_free_f ASN__PRIMITIVE_TYPE_free

Definition at line 17 of file INTEGER.c.

Referenced by NativeInteger_decode_uper(), NativeInteger_decode_xer(), NativeInteger_encode_uper(), and TimestampIts_1_inherit_TYPE_descriptor().

◆ asn_DEF_INTEGER_tags

ber_tlv_tag_t asn_DEF_INTEGER_tags[]
static
Initial value:

Definition at line 14 of file INTEGER.c.