Guardtime KSI c SDK
Data Fields
KSI_TlvTemplate_st Struct Reference

#include <tlv_template.h>

Data Fields

int type
 
unsigned tag
 
unsigned flags
 
getter_t getValue
 
setter_t setValue
 
int(* construct )(KSI_CTX *, void **)
 
void(* destruct )(void *)
 
const KSI_TlvTemplatesubTemplate
 
int(* listAppend )(void *, void *)
 
int multiple
 
int(* listNew )(void **)
 
void(* listFree )(void *)
 
int(* listLength )(const void *)
 
int(* listElementAt )(const void *, int, void **)
 
int(* fromTlv )(KSI_TLV *tlv, void **)
 
int(* toTlv )(KSI_CTX *, void *, unsigned, int, int, KSI_TLV **tlv)
 
const char * descr
 
parse_t parser
 
int parser_opt
 
int(* setRaw )(void *, KSI_OctetString *)
 

Detailed Description

TLV template structure.

Field Documentation

int(* KSI_TlvTemplate_st::construct) (KSI_CTX *, void **)

Object value basic constructor.

const char* KSI_TlvTemplate_st::descr

Free text description of the template.

void(* KSI_TlvTemplate_st::destruct) (void *)

Object value destructor.

unsigned KSI_TlvTemplate_st::flags
int(* KSI_TlvTemplate_st::fromTlv) (KSI_TLV *tlv, void **)

Simple function for converting a TLV into an object.

getter_t KSI_TlvTemplate_st::getValue

Getter function for the object value.

int(* KSI_TlvTemplate_st::listAppend) (void *, void *)

If the object is a list, this function is used to add the element to it.

int(* KSI_TlvTemplate_st::listElementAt) (const void *, int, void **)

If the object is a list, this function is used for random access of its elements.

void(* KSI_TlvTemplate_st::listFree) (void *)

If the object is a list, this function is used to free the memory of it when an error occurs.

int(* KSI_TlvTemplate_st::listLength) (const void *)

If the object is a list, this function is used to get the length of it.

int(* KSI_TlvTemplate_st::listNew) (void **)

If the object is a list, this function is used to initialize the list object.

int KSI_TlvTemplate_st::multiple

Can this element be added multiple times? If this value is 0, an error is thrown when more than one TLV of this tag is encountered in a single composite element.

parse_t KSI_TlvTemplate_st::parser
int KSI_TlvTemplate_st::parser_opt
int(* KSI_TlvTemplate_st::setRaw) (void *, KSI_OctetString *)
setter_t KSI_TlvTemplate_st::setValue

Setter function for the object value.

const KSI_TlvTemplate* KSI_TlvTemplate_st::subTemplate

If the current tag is a composite TLV (i.e not a primitive type), the composite element is parsed using this sub-template.

unsigned KSI_TlvTemplate_st::tag

TLV tag value.

int(* KSI_TlvTemplate_st::toTlv) (KSI_CTX *, void *, unsigned, int, int, KSI_TLV **tlv)

Simple function for converting an object into a TLV.

int KSI_TlvTemplate_st::type

Template internal type.


The documentation for this struct was generated from the following file: