Skip to content

Commit

Permalink
refactor: minor stuff
Browse files Browse the repository at this point in the history
  • Loading branch information
MichaelKreil committed Nov 11, 2024
1 parent 9796d82 commit db98392
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 0 deletions.
4 changes: 4 additions & 0 deletions versatiles_derive/src/decode_vpl/decode_struct.rs
Original file line number Diff line number Diff line change
Expand Up @@ -64,6 +64,10 @@ pub fn decode_struct(input: DeriveInput, data_struct: DataStruct) -> TokenStream
format!("* *`{field_str}`: Boolean (optional, default: false)*{comment}"),
quote! { #field_name: node.get_property_bool_req(#field_str)? },
),
"u8" => (
format!("* *`{field_str}`: u8 *{comment}"),
quote! { #field_name: node.get_property_number_req::<u8>(#field_str)? },
),
"[f64;4]" => (
format!("* **`{field_str}`: [f64,f64,f64,f64] (required)**{comment}"),
quote! { #field_name: node.get_property_number_array4_req::<f64>(#field_str)? },
Expand Down
4 changes: 4 additions & 0 deletions versatiles_geometry/src/vector_tile/layer.rs
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,10 @@ impl VectorTileLayer {
}
}

pub fn new_standard(name: String) -> VectorTileLayer {
VectorTileLayer::new(name, 4096, 1)
}

pub fn read(reader: &mut dyn ValueReader<'_, LE>) -> Result<VectorTileLayer> {
let mut extent = 4096;
let mut features: Vec<VectorTileFeature> = Vec::new();
Expand Down

0 comments on commit db98392

Please sign in to comment.