trs-data-value

Crates.iotrs-data-value
lib.rstrs-data-value
version0.1.2
sourcesrc
created_at2024-12-05 20:23:55.692529
updated_at2024-12-10 18:46:37.121877
descriptionData Value for common data types
homepage
repository
max_upload_size
id1473585
size290,576
(spigi42)

documentation

README

DataValue

Description

This is just simple wrapper for different data types. It's building block for dataframe and other parts of eco-system.

Usage

use data_value::{stdhashmap, DataValue, datavalue};

let dataset = datavalue!(
        "name" => "test",
        "age"=> 42i64,
        "address"=> datavalue!{
            "city" => "test",
            "street"=> "test"
        },
        "list"=> datavalue!([1i64, 2i64, 3i64])
);

let json_dataset = serde_json::json!({
        "name": "test",
        "age": 42,
        "address": {
            "city": "test",
            "street": "test"
        },
        "list": [1, 2, 3]
    });
let json_dv = DataValue::from(json_dataset);

assert_eq!(dataset, json_dv);

Coverage

cargo llvm-cov --lcov --output-path lcov.info

Commit count: 0

cargo fmt