![]() |
MobilityDB 1.3
|
A simple program that reads AIS data from a CSV file, accumulates the observations in main memory and send the temporal values to an output file when they reach a given number of instants in order to free the memory and ingest the newest observations. More...
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <meos.h>
#include <meos_geo.h>
#include <meos_internal.h>
Data Structures | |
struct | AIS_record |
struct | trip_record |
Macros | |
#define | MAX_LENGTH_HEADER 1024 |
#define | MAX_LENGTH_POINT 64 |
#define | MAX_TRIPS 5 |
#define | NO_INSTANTS_BATCH 1000 |
#define | NO_INSTANTS_KEEP 2 |
Functions | |
int | main (int argc, char **argv) |
A simple program that reads AIS data from a CSV file, accumulates the observations in main memory and send the temporal values to an output file when they reach a given number of instants in order to free the memory and ingest the newest observations.
This program is similar to 04_ais_stream_db
but illustrates the use of an output file. In this setting, the expandable data structures accumulate the observations that have been received so far and append them to the file. Depending on application requirements and the available memory, the accumulated temporal values must be sent regularly to the file.
The program can be build as follows