datarecord.h File Reference

ASTERIX data record. More...

#include "category.h"
#include "uap.h"
#include "fspec.h"
#include "dataitem.h"
#include "match.h"
#include "type.h"
Include dependency graph for datarecord.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Data Structures

struct  ast_datarecord_t
 Datarecord. More...
struct  ast_datarecord_ex_t
 Extracted datarecord. More...
struct  ast_datarecord_modifier_t
 Datarecord modifier. More...

Macros

#define AST_MAX_DATAITEMS   32
 Maximum number of data items in a data record.
#define AST_DATARECORD_HEX_HTML_PREFERED_CHARS   (AST_MAX_DATAITEMS * AST_MAX_DATAITEM_SIZE * 12 + 128)
 Preferred number of chars of datarecord hexadecimal HTML snippet.
#define AST_DATARECORD_DETAIL_HTML_PREFERED_CHARS   20480
 Preferred number of chars of data item detail description HTML snippet.
#define AST_KEYWORD_VALUE_PREFERRED_CHARS   32
 Preferred number of chars of keyword string.

Functions

ast_datarecord_t ast_datarecord_decode (const unsigned char *buffer, const size_t bufsize, const ast_category_t category, const ast_uap_t uap)
 Datarecord decode function.
ast_datarecord_t ast_datarecord_encode (unsigned char *const buffer, const size_t bufsize, const ast_datarecord_ex_t xdr)
 Datarecord encode function.
ast_datarecord_t ast_datarecord_copy (unsigned char *buffer, const size_t bufsize, const ast_datarecord_t src)
 Datarecord copy function.
ast_datarecord_t ast_datarecord_modify (unsigned char *buffer, const size_t bufsize, const ast_datarecord_t src, const ast_datarecord_modifier_t mod)
 Datarecord modify function.
void ast_datarecord_get_hex_html (char *html, const size_t html_size, const ast_datarecord_t dr)
 Function to get a html snippet of the raw datarecord data in hexadecimal format.
void ast_datarecord_get_detail_html (char *detail, const size_t detail_size, const ast_datarecord_t dr)
 Function to get a html snippet of detailed description of data record.
bool ast_datarecord_contain_keyword (const ast_datarecord_t dr, const ast_keyword_t keyword)
 Check if datarecord contains specified keyword type.
bool ast_datarecord_match_keyword (const ast_datarecord_t dr, const ast_keyword_t keyword, const char *challenge, bool case_sensitive)
 Match a specified keyword in the datarecord.
bool ast_datarecord_get_keyword (char *keystr, const size_t keystr_size, const ast_datarecord_t dr, const ast_keyword_t keyword, const ast_keyword_format_t format)
 Get keyword summary string from specified datarecord.
ast_sacsic_t ast_datarecord_get_sacsic (const ast_datarecord_t dr)
 Get SAC/SIC from specified datarecord.
ast_timeofday_t ast_datarecord_get_timeofday (const ast_datarecord_t dr)
 Get time of day from specified datarecord.
ast_msgtype_t ast_datarecord_get_msgtype (const ast_datarecord_t dr)
 Get message type from specified datarecord.
ast_tracknum_t ast_datarecord_get_tracknum (const ast_datarecord_t dr)
 Get track number from specified datarecord.
ast_squawk_t ast_datarecord_get_squawk (const ast_datarecord_t dr)
 Get Mode-3/A code from specified datarecord.
ast_callsign_t ast_datarecord_get_callsign (const ast_datarecord_t dr)
 Get callsign from specified datarecord.
ast_icaoaddr_t ast_datarecord_get_icaoaddr (const ast_datarecord_t dr)
 Get ICAO 24-bit address from specified datarecord.
ast_wgs84coord_t ast_datarecord_get_wgs84coord (const ast_datarecord_t dr)
 Get WGS-84 coordinate from specified datarecord.
ast_altitude_t ast_datarecord_get_flightlevel (const ast_datarecord_t dr)
 Get flight level from specified datarecord.
ast_altitude_t ast_datarecord_get_selaltitude (const ast_datarecord_t dr)
 Get FMS/MCP/FCU selected altitude from specified datarecord.
ast_polar_coordinate_t ast_datarecord_get_polarcoord (const ast_datarecord_t dr)
 Get polar coordinate from specified datarecord.
ast_range_t ast_datarecord_get_range (const ast_datarecord_t dr)
 Get range from specified datarecord.
ast_azimuth_t ast_datarecord_get_azimuth (const ast_datarecord_t dr)
 Get azimuth from specified datarecord.
ast_heading_t ast_datarecord_get_heading (const ast_datarecord_t dr)
 Get heading from specified datarecord.
ast_speed_t ast_datarecord_get_speed (const ast_datarecord_t dr)
 Get speed from specified datarecord.
ast_cartesian_velocity_t ast_datarecord_get_cartesianvel (const ast_datarecord_t dr)
 Get cartesian velocity from specified datarecord.
ast_doppler_velocity_t ast_datarecord_get_dopplervel (const ast_datarecord_t dr)
 Get doppler velocity from specified datarecord.
ast_vertical_rate_t ast_datarecord_get_vrate (const ast_datarecord_t dr)
 Get vertical rate from specified datarecord.

Detailed Description

ASTERIX data record.

Description:
This file declares the data record structures and the decode/encode/copy/modify/keyword interfaces for ASTERIX data record processing.