23 #ifndef LIBASTERIX_SUBFIELD_H 24 #define LIBASTERIX_SUBFIELD_H 46 #define AST_MAP_SUBFIELD_TYPE_EX(category_name, category_value, dataitem, subfield) \ 47 I ## category_name ## _ ## dataitem ## _ ## S ## subfield = category_value ## dataitem ## 0 ## subfield, 52 typedef enum _ast_subfield_type_t
57 #define AST_MAP_SUBFIELD_TYPE(category, dataitem, subfield) AST_MAP_SUBFIELD_TYPE_EX(00 ## category, category, dataitem, subfield) 98 #undef AST_MAP_SUBFIELD_TYPE 99 #define AST_MAP_SUBFIELD_TYPE(category, dataitem, subfield) AST_MAP_SUBFIELD_TYPE_EX(0 ## category, category, dataitem, subfield) 292 typedef struct _ast_subfield_t
305 #define AST_MAX_SUBFIELD_SIZE 32 317 #define AST_SUBFIELD_SUMMARY_PREFERED_CHARS summary_size 326 #define AST_SUBFIELD_BIN_HTML_PREFERED_CHARS (AST_MAX_SUBFIELD_SIZE * 128 + 64) 362 #define AST_MAX_SUBFIELDS 35 365 typedef struct _ast_dataitem_subfields_t
396 #endif //LIBASTERIX_SUBFIELD_H ast_subfield_type_t
Definition of subfield id in each dataitem.
Definition: subfield.h:52
bool existing
Definition: subfield.h:294
bool valid
True if subfield is correctlly decoded.
Definition: subfield.h:301
const char * ast_subfield_get_id(const ast_subfield_type_t type)
Get ID string of subfield.
bool valid
Definition: subfield.h:367
ast_dataitem_subfields_t ast_dataitem_subfields_decode(const ast_dataitem_t di)
Decode function.
Null subfield.
Definition: subfield.h:54
void ast_subfield_get_bin_html(char *html, const size_t html_size, const ast_subfield_t sf)
Function to get a html snippet of the raw subfield data in binary format.
ast_subfield_type_t type
Type of subfield.
Definition: subfield.h:299
size_t ast_subfield_get_size(const unsigned char *buffer, const size_t bufsize, const ast_subfield_type_t type)
Get size of subfield.
Implementation of Field SPECification (FSPEC) concept defined by ASTERIX.
size_t n_subfields
Definition: subfield.h:371
#define AST_MAP_SUBFIELD_TYPE(category, dataitem, subfield)
Definition: subfield.h:99
Subfield struct.
Definition: subfield.h:292
Implementation of Dataitem concept defined by ASTERIX.
size_t ast_dataitem_subfields_get_size(const unsigned char *buffer, const size_t bufsize, const ast_dataitem_type_t dataitem)
Get size function.
const char * ast_subfield_get_name(const ast_subfield_type_t type)
Get name of subfield.
ast_fspec_t fspec
Definition: subfield.h:369
void ast_dataitem_subfields_get_detail_html(char *detail, const size_t detail_size, const ast_dataitem_t di)
Get detail function.
const unsigned char * data
Address of subfield.
Definition: subfield.h:296
Dataitem.
Definition: dataitem.h:422
void ast_subfield_get_detail_html(char *detail, const size_t detail_size, const ast_dataitem_t di, const ast_subfield_type_t type)
Get detail of subfield, in html format.
size_t size
Size of subfield.
Definition: subfield.h:297
ast_dataitem_type_t
Definition of data item id in each category.
Definition: dataitem.h:67
#define AST_MAX_SUBFIELDS
Definition: subfield.h:362
size_t ast_dataitem_subfields_get_number(const ast_dataitem_type_t type)
Get number of subfields function.
void ast_dataitem_subfields_get_summary(char *summary, const size_t summary_size, const ast_dataitem_t di)
Get summary funciton.
void ast_subfield_get_summary(char *summary, const size_t summary_size, const ast_dataitem_t di, const ast_subfield_type_t type)
Get summary of subfield.
Data Item - Subfields.
Definition: subfield.h:365