MCPcopy Create free account
hub / github.com/biblius/validify / str_slice_to_string

Function str_slice_to_string

derive_tests/tests/validify.rs:6–8  ·  view source on GitHub ↗

Use for `in/not_in` validation to convert the slices to strings.

(slice: &[&str])

Source from the content-addressed store, hash-verified

4
5/// Use for `in/not_in` validation to convert the slices to strings.
6pub fn str_slice_to_string(slice: &[&str]) -> Vec<String> {
7 slice.iter().map(|el| String::from(*el)).collect()
8}
9
10#[derive(Debug, Deserialize, Validify, Payload)]
11struct HasVec {

Callers

nothing calls this directly

Calls 1

collectMethod · 0.80

Tested by

no test coverage detected