pub enum PollKind {
Undisclosed,
Disclosed,
// some variants omitted
}
Available on crate features
events
and unstable-msc3381
only.Expand description
The kind of poll.
This type can hold an arbitrary string. To build this with a custom value, convert it from a
string with ::from()
/ .into()
. To check for values that are not available as a
documented variant here, use its string representation, obtained through
.as_str()
.
Variants
Undisclosed
The results are revealed once the poll is closed.
Disclosed
The votes are visible up until and including when the poll is closed.
Implementations
Trait Implementations
sourceimpl<'de> Deserialize<'de> for PollKind
impl<'de> Deserialize<'de> for PollKind
sourcefn deserialize<D>(
deserializer: D
) -> Result<PollKind, <D as Deserializer<'de>>::Error>where
D: Deserializer<'de>,
fn deserialize<D>(
deserializer: D
) -> Result<PollKind, <D as Deserializer<'de>>::Error>where
D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
sourceimpl Serialize for PollKind
impl Serialize for PollKind
sourcefn serialize<S>(
&self,
serializer: S
) -> Result<<S as Serializer>::Ok, <S as Serializer>::Error>where
S: Serializer,
fn serialize<S>(
&self,
serializer: S
) -> Result<<S as Serializer>::Ok, <S as Serializer>::Error>where
S: Serializer,
Serialize this value into the given Serde serializer. Read more
impl Eq for PollKind
impl StructuralEq for PollKind
impl StructuralPartialEq for PollKind
Auto Trait Implementations
impl RefUnwindSafe for PollKind
impl Send for PollKind
impl Sync for PollKind
impl Unpin for PollKind
impl UnwindSafe for PollKind
Blanket Implementations
sourceimpl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
const: unstable · sourcefn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
sourceimpl<Q, K> Equivalent<K> for Qwhere
Q: Eq + ?Sized,
K: Borrow<Q> + ?Sized,
impl<Q, K> Equivalent<K> for Qwhere
Q: Eq + ?Sized,
K: Borrow<Q> + ?Sized,
sourcefn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key
and return true
if they are equal.