pub struct Submission { /* private fields */ }
Implementations§
Source§impl Submission
impl Submission
pub fn graded(&self) -> bool
pub fn submitted(&self) -> bool
pub fn ungraded(&self) -> bool
pub fn unsubmitted(&self) -> bool
pub fn grade_100(&self) -> bool
pub fn grade_not_100(&self) -> bool
pub fn assignment(&self) -> u64
pub fn attempt(&self) -> u64
pub fn user(&self) -> u64
pub fn files(&self) -> Option<Vec<FileSubmission>>
pub async fn assignment_submissions( assignment_id: u64, predicate: &dyn Fn(&Self) -> bool, config: &Config, ) -> Result<Vec<Self>>
pub async fn count_submissions( assignment_id: u64, predicate: &dyn Fn(&Self) -> bool, config: &Config, ) -> Result<usize>
pub async fn update_grades( assignment_id: u64, grades: &[Grade], config: &Config, ) -> Result<()>
pub async fn update_grades_with_comments( assignment_id: u64, grades: &[Grade], comments: &[Comment], config: &Config, ) -> Result<()>
Trait Implementations§
Source§impl Debug for Submission
impl Debug for Submission
Source§impl<'de> Deserialize<'de> for Submission
impl<'de> Deserialize<'de> for Submission
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
Auto Trait Implementations§
impl Freeze for Submission
impl RefUnwindSafe for Submission
impl Send for Submission
impl Sync for Submission
impl Unpin for Submission
impl UnwindSafe for Submission
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> 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 moreSource§impl<T> PolicyExt for Twhere
T: ?Sized,
impl<T> PolicyExt for Twhere
T: ?Sized,
Source§impl<T> ToStringFallible for Twhere
T: Display,
impl<T> ToStringFallible for Twhere
T: Display,
Source§fn try_to_string(&self) -> Result<String, TryReserveError>
fn try_to_string(&self) -> Result<String, TryReserveError>
ToString::to_string
, but without panic on OOM.