pub struct Poll {
pub id: u64,
pub question: Option<String>,
pub description: Option<String>,
pub total_results: Option<Value>,
/* private fields */
}Expand description
A Canvas poll created by the current user.
Fields§
§id: u64§question: Option<String>§description: Option<String>§total_results: Option<Value>Implementations§
Source§impl Poll
impl Poll
Sourcepub async fn update(&self, params: CreatePollParams) -> Result<Poll>
pub async fn update(&self, params: CreatePollParams) -> Result<Poll>
Sourcepub async fn get_choice(&self, choice_id: u64) -> Result<PollChoice>
pub async fn get_choice(&self, choice_id: u64) -> Result<PollChoice>
Sourcepub fn get_choices(&self) -> PageStream<PollChoice>
pub fn get_choices(&self) -> PageStream<PollChoice>
Sourcepub async fn create_choice(
&self,
params: PollChoiceParams,
) -> Result<PollChoice>
pub async fn create_choice( &self, params: PollChoiceParams, ) -> Result<PollChoice>
Sourcepub async fn get_session(&self, session_id: u64) -> Result<PollSession>
pub async fn get_session(&self, session_id: u64) -> Result<PollSession>
Sourcepub fn get_sessions(&self) -> PageStream<PollSession>
pub fn get_sessions(&self) -> PageStream<PollSession>
Sourcepub async fn create_session(
&self,
params: PollSessionParams,
) -> Result<PollSession>
pub async fn create_session( &self, params: PollSessionParams, ) -> Result<PollSession>
Trait Implementations§
Source§impl<'de> Deserialize<'de> for Poll
impl<'de> Deserialize<'de> for Poll
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 Poll
impl !RefUnwindSafe for Poll
impl Send for Poll
impl Sync for Poll
impl Unpin for Poll
impl UnsafeUnpin for Poll
impl !UnwindSafe for Poll
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