Functions | |
| int | beatl2_init (void) |
| void | beatl2_done (void) |
Variables | |
| const char * | libbeatl2_version |
The BEAT-II General module contains the BEAT-II initialization and finalization functions of BEAT-II. Before you call any other function of BEAT-II you should initialize BEAT-II with a call to beatl2_init(). This function will initialize the underlying CODA library that is used for the direct data access and will initialize all BEAT-II ingestion modules. After you are finished with BEAT-II you should call beatl2_done() in order to properly deallocate any resources that were claimed by beatl2_init().
Note that the CODA library may require access to .codadef files that describe the formats of certain product files. In order to tell CODA where these .codadef files are located you will, before calling beatl2_init(), have to either set a CODA_DEFINITION environment variable with the proper path or set the path programmatically using the coda_set_definition_path() function through the CODA C library interface.
| void beatl2_done | ( | void | ) |
Finalizes the BEAT-II C library. This function should be called to let the BEAT-II library free up any resources it has claimed since initialization.
It is valid to perform multiple calls to beatl2_init() after each other. Only the first call to beatl2_init() will do the actual initialization and all following calls to beatl2_init() will only increase an initialization counter. Each call to beatl2_init() needs to be matched by a call to beatl2_done() at clean-up time (i.e. the amount of calls to beatl2_done() needs to be equal to the amount of calls to beatl2_init()). Only the last beatl2_done() call (when the initialization counter has reached 0) will do the actual clean-up of the BEAT-II C library (and underlying CODA library).
Calling a BEAT-II function other than beatl2_init() after the final beatl2_done() will result in undefined behavior.
| int beatl2_init | ( | void | ) |
Initializes the BEAT-II C library. This function should be called before any other BEAT-II C library function is called.
The beatl2_init() function will also initialize the underlying CODA library that is used for the direct data access. Note that the CODA library may require access to .codadef files that describe the formats of certain product files. In order to tell CODA where these .codadef files are located you will, before calling beatl2_init(), have to either set a CODA_DEFINITION environment variable with the proper path or set the path programmatically using the coda_set_definition_path() function that is available in the CODA C library interface.
It is valid to perform multiple calls to beatl2_init() after each other. Only the first call to beatl2_init() will do the actual initialization and all following calls to beatl2_init() will only increase an initialization counter (this also means that it is important that you set the CODA definition path before the first call to beatl2_init() is performed; changing the CODA definition path afterwards will have no effect). Each call to beatl2_init() needs to be matched by a call to beatl2_done() at clean-up time (i.e. the amount of calls to beatl2_done() needs to be equal to the amount of calls to beatl2_init()). Only the last beatl2_done() call (when the initialization counter has reached 0) will do the actual clean-up of the BEAT-II C library (and underlying CODA library).
0, Success. -1, Error occurred (check beatl2_errno). | const char* libbeatl2_version |
Current version of BEAT as a string.