ESDM
Middleware for Earth System Data
|
Entry point for ESDM API Implementation. More...
#include <stdbool.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <esdm-internal.h>
Macros | |
#define | ESDM_INSTANCE_INITIALIZERS |
Functions | |
esdm_instance_t * | esdmI_esdm () |
esdm_status | esdm_set_procs_per_node (int procs) |
esdm_status | esdm_set_total_procs (int procs) |
esdm_status | esdm_load_config_str (const char *str) |
esdm_status | esdm_dataset_get_dataspace (esdm_dataset_t *dset, esdm_dataspace_t **out_dataspace) |
int | esdm_is_initialized () |
esdm_status | esdm_init () |
esdm_modules_t * | esdm_get_modules () |
esdm_status | esdm_mkfs (int format_flags, data_accessibility_t target) |
esdm_status | esdm_finalize () |
esdm_status | esdm_write (esdm_dataset_t *dataset, void *buf, esdm_dataspace_t *space) |
esdm_status | esdmI_readWithFillRegion (esdm_dataset_t *dataset, void *buf, esdm_dataspace_t *space, esdmI_hypercubeSet_t **out_fillRegion) |
esdm_status | esdm_read (esdm_dataset_t *dataset, void *buf, esdm_dataspace_t *space) |
esdm_status | esdm_sync () |
int | esdm_container_get_mode_flags (esdm_container_t *c) |
esdm_status | esdm_dataset_set_fill_value (esdm_dataset_t *d, void const *value) |
int | esdm_dataset_is_fill_value_set (esdm_dataset_t *d) |
esdm_status | esdm_dataset_get_fill_value (esdm_dataset_t *d, void *value) |
esdm_status | esdm_dataset_change_name (esdm_dataset_t *d, char const *new_name) |
esdm_status | esdm_read_stream (esdm_dataset_t *d, esdm_dataspace_t *space, void *user_ptr, esdm_stream_func_t stream_func, esdm_reduce_func_t reduce_func) |
esdm_statistics_t | esdm_read_stats () |
esdm_statistics_t | esdm_write_stats () |
esdm_config_t * | esdmI_getConfig () |
Entry point for ESDM API Implementation.
#define ESDM_INSTANCE_INITIALIZERS |
esdm_status esdm_dataset_get_dataspace | ( | esdm_dataset_t * | dset, |
esdm_dataspace_t ** | out_dataspace | ||
) |
Inquire the shape of a dataset.
[in] | dset | the dataset to question |
[out] | out_dataspace | a reference to the dataset's dataspace |
The dataset remains the owner of the dataspace, the caller must not destroy it.
esdm_status esdm_finalize | ( | ) |
Display status information for objects stored in ESDM.
esdm_status esdm_init | ( | ) |
Initialize ESDM:
esdm_status esdm_load_config_str | ( | const char * | str | ) |
Set the configuration to use. Must not be called after init()
, and must not be called twice.
[in] | str | a string containing configuration data in JSON format |
esdm_status esdm_read | ( | esdm_dataset_t * | dataset, |
void * | buf, | ||
esdm_dataspace_t * | subspace | ||
) |
Identical to esdm_write except that it uses size/offset tuples instead of the subspace Reads a data fragment described by desc to the dataset dset.
[in] | dataset | TODO, currently a stub, we assume it has been identified/created before.... , json description? |
[out] | buf | a contiguous memory region that shall be filled with the data from permanent storage |
[in] | subspace | an existing dataspace that describes the shape and location of the hypercube that is to be read |
esdm_statistics_t esdm_read_stats | ( | ) |
Get some statistics about the reads that have been performed.
esdm_status esdm_set_procs_per_node | ( | int | procs | ) |
Set the number of processes to use per node. Must not be called after init()
.
[in] | procs | the number of processes to use per node |
esdm_status esdm_set_total_procs | ( | int | procs | ) |
Set the total number of processes to use. Must not be called after init()
.
[in] | procs | the number of processes to use |
esdm_status esdm_write | ( | esdm_dataset_t * | dataset, |
void * | buf, | ||
esdm_dataspace_t * | subspace | ||
) |
Write data with a given size and offset.
[in] | dataset | TODO, currently a stub, we assume it has been identified/created before...., json description? |
[in] | buf | the pointer to a contiguous memory region that shall be written to permanent storage |
[in] | subspace | an existing dataspace that describes the shape and location of the hypercube that is to be written |
esdm_statistics_t esdm_write_stats | ( | ) |
Get some statistics about the writes that have been performed.
esdm_status esdmI_readWithFillRegion | ( | esdm_dataset_t * | dataset, |
void * | buf, | ||
esdm_dataspace_t * | memspace, | ||
esdmI_hypercubeSet_t ** | out_fillRegion | ||
) |
As esdm_read()
, but also return the region that was filled with the fill value as a hypercube set. If no fill value is set and any region without data is detected, this call will still return an error.
[in] | dataset | TODO, currently a stub, we assume it has been identified/created before.... , json description? |
[out] | buf | a contiguous memory region that shall be filled with the data from permanent storage |
[in] | memspace | a dataspace that describes the location, size, and memory layout of the part of the data that is to be read |
[out] | out_fillRegion | returns a new esdmI_hypercubeSet_t* that covers the region for which no data was found. |