pub struct TaskQuery {
pub platform_id: String,
pub states: Vec<i32>,
pub min_priority: i32,
pub include_statistics: bool,
}Expand description
Query for tasks
Fields§
§platform_id: StringFilter by platform ID
states: Vec<i32>Filter by task state
min_priority: i32Filter by priority
include_statistics: boolInclude task statistics
Implementations§
Source§impl TaskQuery
impl TaskQuery
Sourcepub fn states(
&self,
) -> FilterMap<Cloned<Iter<'_, i32>>, fn(i32) -> Option<TaskState>>
pub fn states( &self, ) -> FilterMap<Cloned<Iter<'_, i32>>, fn(i32) -> Option<TaskState>>
Returns an iterator which yields the valid enum values contained in states.
Sourcepub fn push_states(&mut self, value: TaskState)
pub fn push_states(&mut self, value: TaskState)
Appends the provided enum value to states.
Sourcepub fn min_priority(&self) -> TaskPriority
pub fn min_priority(&self) -> TaskPriority
Returns the enum value of min_priority, or the default if the field is set to an invalid enum value.
Sourcepub fn set_min_priority(&mut self, value: TaskPriority)
pub fn set_min_priority(&mut self, value: TaskPriority)
Sets min_priority to the provided enum value.
Trait Implementations§
Source§impl<'de> Deserialize<'de> for TaskQuery
impl<'de> Deserialize<'de> for TaskQuery
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
Source§impl Message for TaskQuery
impl Message for TaskQuery
Source§fn encoded_len(&self) -> usize
fn encoded_len(&self) -> usize
Returns the encoded length of the message without a length delimiter.
Source§fn encode(&self, buf: &mut impl BufMut) -> Result<(), EncodeError>where
Self: Sized,
fn encode(&self, buf: &mut impl BufMut) -> Result<(), EncodeError>where
Self: Sized,
Encodes the message to a buffer. Read more
Source§fn encode_to_vec(&self) -> Vec<u8> ⓘwhere
Self: Sized,
fn encode_to_vec(&self) -> Vec<u8> ⓘwhere
Self: Sized,
Encodes the message to a newly allocated buffer.
Source§fn encode_length_delimited(
&self,
buf: &mut impl BufMut,
) -> Result<(), EncodeError>where
Self: Sized,
fn encode_length_delimited(
&self,
buf: &mut impl BufMut,
) -> Result<(), EncodeError>where
Self: Sized,
Encodes the message with a length-delimiter to a buffer. Read more
Source§fn encode_length_delimited_to_vec(&self) -> Vec<u8> ⓘwhere
Self: Sized,
fn encode_length_delimited_to_vec(&self) -> Vec<u8> ⓘwhere
Self: Sized,
Encodes the message with a length-delimiter to a newly allocated buffer.
Source§fn decode(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
fn decode(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
Decodes an instance of the message from a buffer. Read more
Source§fn decode_length_delimited(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
fn decode_length_delimited(buf: impl Buf) -> Result<Self, DecodeError>where
Self: Default,
Decodes a length-delimited instance of the message from the buffer.
Source§fn merge(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
fn merge(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
Decodes an instance of the message from a buffer, and merges it into
self. Read moreSource§fn merge_length_delimited(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
fn merge_length_delimited(&mut self, buf: impl Buf) -> Result<(), DecodeError>where
Self: Sized,
Decodes a length-delimited instance of the message from buffer, and
merges it into
self.impl StructuralPartialEq for TaskQuery
Auto Trait Implementations§
impl Freeze for TaskQuery
impl RefUnwindSafe for TaskQuery
impl Send for TaskQuery
impl Sync for TaskQuery
impl Unpin for TaskQuery
impl UnsafeUnpin for TaskQuery
impl UnwindSafe for TaskQuery
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