Struct carapax::types::GiveawayCompleted
source · pub struct GiveawayCompleted {
pub winner_count: i64,
pub giveaway_message: Option<Box<Message>>,
pub unclaimed_prize_count: Option<i64>,
}
Expand description
Represents a service message about the completion of a giveaway without public winners.
Fields§
§winner_count: i64
Number of winners in the giveaway.
giveaway_message: Option<Box<Message>>
Message with the giveaway that was completed, if it wasn’t deleted.
unclaimed_prize_count: Option<i64>
Number of undistributed prizes.
Implementations§
source§impl GiveawayCompleted
impl GiveawayCompleted
sourcepub fn new(winner_count: i64) -> GiveawayCompleted
pub fn new(winner_count: i64) -> GiveawayCompleted
sourcepub fn with_giveaway_message(self, value: Message) -> GiveawayCompleted
pub fn with_giveaway_message(self, value: Message) -> GiveawayCompleted
sourcepub fn with_unclaimed_prize_count(self, value: i64) -> GiveawayCompleted
pub fn with_unclaimed_prize_count(self, value: i64) -> GiveawayCompleted
Trait Implementations§
source§impl Clone for GiveawayCompleted
impl Clone for GiveawayCompleted
source§fn clone(&self) -> GiveawayCompleted
fn clone(&self) -> GiveawayCompleted
Returns a copy of the value. Read more
1.0.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moresource§impl Debug for GiveawayCompleted
impl Debug for GiveawayCompleted
source§impl<'de> Deserialize<'de> for GiveawayCompleted
impl<'de> Deserialize<'de> for GiveawayCompleted
source§fn deserialize<__D>(
__deserializer: __D
) -> Result<GiveawayCompleted, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(
__deserializer: __D
) -> Result<GiveawayCompleted, <__D as Deserializer<'de>>::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
source§impl PartialEq for GiveawayCompleted
impl PartialEq for GiveawayCompleted
source§fn eq(&self, other: &GiveawayCompleted) -> bool
fn eq(&self, other: &GiveawayCompleted) -> bool
This method tests for
self
and other
values to be equal, and is used
by ==
.source§impl Serialize for GiveawayCompleted
impl Serialize for GiveawayCompleted
source§fn 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 StructuralPartialEq for GiveawayCompleted
Auto Trait Implementations§
impl Freeze for GiveawayCompleted
impl RefUnwindSafe for GiveawayCompleted
impl Send for GiveawayCompleted
impl Sync for GiveawayCompleted
impl Unpin for GiveawayCompleted
impl UnwindSafe for GiveawayCompleted
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 more