pub enum ModerationCause {
Blocking {
source: ModerationCauseSource,
priority: u8,
downgraded: bool,
},
BlockedBy {
source: ModerationCauseSource,
priority: u8,
downgraded: bool,
},
BlockOther {
source: ModerationCauseSource,
priority: u8,
downgraded: bool,
},
Label {
source: ModerationCauseSource,
label: LabelData,
label_def: LabelValueDefinition,
target: LabelTarget,
setting: LabelPreference,
no_override: bool,
priority: u8,
downgraded: bool,
},
Muted {
source: ModerationCauseSource,
priority: u8,
downgraded: bool,
},
MuteWord {
source: ModerationCauseSource,
priority: u8,
downgraded: bool,
},
Hidden {
source: ModerationCauseSource,
priority: u8,
downgraded: bool,
},
}Expand description
A single cause for a moderation decision.
Variants§
Blocking
BlockedBy
BlockOther
Label
Fields
§
source: ModerationCauseSource§
label_def: LabelValueDefinition§
target: LabelTarget§
setting: LabelPreferenceMuted
MuteWord
Hidden
Implementations§
Source§impl ModerationCause
impl ModerationCause
pub const fn priority(&self) -> u8
pub const fn is_downgraded(&self) -> bool
pub const fn set_downgraded(&mut self)
Trait Implementations§
Source§impl Clone for ModerationCause
impl Clone for ModerationCause
Source§fn clone(&self) -> ModerationCause
fn clone(&self) -> ModerationCause
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl Freeze for ModerationCause
impl RefUnwindSafe for ModerationCause
impl Send for ModerationCause
impl Sync for ModerationCause
impl Unpin for ModerationCause
impl UnsafeUnpin for ModerationCause
impl UnwindSafe for ModerationCause
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