Struct PollRequest
pub struct PollRequest {
pub recipient: String,
pub question: String,
pub options: Vec<String>,
pub selectable_count: u32,
}Expand description
A native poll to post in a chat.
Channels that cannot post one report Channel::supports_native_polls as
false, and callers fall back to whatever they did before.
Fields§
§recipient: StringChat or peer to post the poll in, in the channel’s own addressing.
question: String§options: Vec<String>Answer options, in the order they should be shown.
selectable_count: u32How many options one voter may pick. 1 is a single-choice poll.
Implementations§
Source§impl PollRequest
impl PollRequest
Trait Implementations§
Source§impl Clone for PollRequest
impl Clone for PollRequest
Source§fn clone(&self) -> PollRequest
fn clone(&self) -> PollRequest
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · §fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for PollRequest
impl Debug for PollRequest
impl Eq for PollRequest
Source§impl PartialEq for PollRequest
impl PartialEq for PollRequest
impl StructuralPartialEq for PollRequest
Auto Trait Implementations§
impl Freeze for PollRequest
impl RefUnwindSafe for PollRequest
impl Send for PollRequest
impl Sync for PollRequest
impl Unpin for PollRequest
impl UnsafeUnpin for PollRequest
impl UnwindSafe for PollRequest
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