mirror of
https://github.com/OMGeeky/google-apis-rs.git
synced 2025-12-26 17:02:24 +01:00
Add docstring
This commit is contained in:
@@ -35,6 +35,8 @@ fn snakecase(source: &str) -> String {
|
||||
pub struct FieldMask(Vec<String>);
|
||||
|
||||
impl FieldMask {
|
||||
/// Create a new `FieldMask` from a list of paths. These are converted to snake
|
||||
/// case if they aren't already.
|
||||
pub fn new<S: AsRef<str>>(values: &[S]) -> Self {
|
||||
return Self(values.iter().map(|s| snakecase(s.as_ref())).collect());
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user