pub struct FieldsetConfig { /* private fields */ }Expand description
Configuration for sparse fieldset filtering.
Implementations§
Source§impl FieldsetConfig
impl FieldsetConfig
Sourcepub fn new() -> Self
pub fn new() -> Self
Create an empty fieldset configuration. Resources with no entry pass through unfiltered.
Sourcepub fn fields(self, type_name: &str, fields: &[&str]) -> Self
pub fn fields(self, type_name: &str, fields: &[&str]) -> Self
Specify which fields to include for a resource type.
Sourcepub fn has_type(&self, type_name: &str) -> bool
pub fn has_type(&self, type_name: &str) -> bool
Check whether this config has an entry for the given type.
Sourcepub fn is_included(&self, type_name: &str, field_name: &str) -> bool
pub fn is_included(&self, type_name: &str, field_name: &str) -> bool
Returns true if: type has no fieldset entry, OR the field is in the type’s fieldset list.
Trait Implementations§
Source§impl Clone for FieldsetConfig
impl Clone for FieldsetConfig
Source§fn clone(&self) -> FieldsetConfig
fn clone(&self) -> FieldsetConfig
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for FieldsetConfig
impl Debug for FieldsetConfig
Auto Trait Implementations§
impl Freeze for FieldsetConfig
impl RefUnwindSafe for FieldsetConfig
impl Send for FieldsetConfig
impl Sync for FieldsetConfig
impl Unpin for FieldsetConfig
impl UnsafeUnpin for FieldsetConfig
impl UnwindSafe for FieldsetConfig
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more