Crate elastic_mapping_macro

Crate elastic_mapping_macro 

Source
Expand description

Procedural macros for the elastic-mapping crate.

This crate provides the #[derive(Document)] macro that automatically generates Elasticsearch mapping implementations for Rust structs and enums.

You typically don’t need to depend on this crate directly. Instead, use the main elastic-mapping crate which re-exports the Document derive macro.

§Example

use elastic_mapping::Document;

#[derive(Document)]
struct MyDocument {
    title: String,
    count: i64,
}

Derive Macros§

Document
Derives Elasticsearch mapping generation for structs and enums.