pub struct UserRule {Show 13 fields
pub id: String,
pub text: String,
pub author: String,
pub reason: String,
pub pattern: Option<String>,
pub verdict: Option<String>,
pub deny_mention: People,
pub deny_reply_to: People,
pub written_at: String,
pub updated_at: String,
pub deleted: bool,
pub from: Option<String>,
pub due_at: Option<String>,
}Expand description
One standing rule. due_at is never written. A sweep drops a row only
when that field is present and already past, which a row this module
writes is not.
Fields§
§id: String§text: String§reason: String§pattern: Option<String>§verdict: Option<String>§deny_mention: People§deny_reply_to: People§written_at: String§updated_at: StringWhen this row last changed. A merge keeps the newer stamp, and with it that row’s author and reason.
deleted: boolA deletion. The row stays so an older copy of the same id does not come back on the next sync.
from: Option<String>The lesson id a promote copied, when this row came from one.
due_at: Option<String>Absent on every row the commands write. Present only so a sweep can drop a row that was given a review date by hand.
Trait Implementations§
Source§impl<'de> Deserialize<'de> for UserRule
impl<'de> Deserialize<'de> for UserRule
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
impl Eq for UserRule
impl StructuralPartialEq for UserRule
Auto Trait Implementations§
impl Freeze for UserRule
impl RefUnwindSafe for UserRule
impl Send for UserRule
impl Sync for UserRule
impl Unpin for UserRule
impl UnsafeUnpin for UserRule
impl UnwindSafe for UserRule
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
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> DeserializeOwned for Twhere
T: for<'de> Deserialize<'de>,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key and return true if they are equal.Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
impl<T> ErasedDestructor for Twhere
T: 'static,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Source§fn in_current_span(self) -> Instrumented<Self> ⓘ
fn in_current_span(self) -> Instrumented<Self> ⓘ
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more