readap
Read OpenDAP binary data with pure rust
Install
with cargo add:
or Cargo.toml:
[]
= "0.1.0"
Getting Started
Read DAS metadata
let attrs = parse_das_attributes.unwrap;
This returns a HashMap containing all of the attributes and their children, within another hashmap
let units: String = attrs.clone.try_into.unwrap;
Read a DDS dataset
let dataset = from_bytes.unwrap;
Read a DODS dataset
let dataset = from_bytes.unwrap;
Then extract the data and coordinates for a given variable
let mwd = if let Int32 = dataset.variable_data.unwrap else ;
let coords = dataset.variable_coords.unwrap;
let time_data: = coords.1.try_into.unwrap;
Build OpenDAP query URLs
let url = dataset.query
.select_variable.unwrap
.dods_url.unwrap;
With coordinate constraints:
let url = dataset.query
.select_variable.unwrap
.select_by_coordinate.unwrap
.select_by_coordinate.unwrap
.dods_url.unwrap;
For concrete examples, see the parse tests
What this library is
This library is an OpenDAP binary data and metadata parser. It is not a data downloader. It is a lower level tool to be used in higher level data access applications.
License
MIT - 2025 Matthew Iannucci