pub struct SubscriptionPhase {
pub uid: Option<String>,
pub cadence: SubscriptionCadence,
pub periods: Option<i32>,
pub recurring_price_money: Money,
pub ordinal: Option<i64>,
}
Expand description
Describes a phase in a subscription plan.
For more information, see Set Up and Manage a Subscription Plan.
Fields§
§uid: Option<String>
The Square-assigned ID of the subscription phase. This field cannot be changed after a
SubscriptionPhase
is created.
cadence: SubscriptionCadence
The billing cadence of the phase. For example, weekly or monthly. This field cannot be
changed after a SubscriptionPhase
is created.
periods: Option<i32>
The number of cadence
s the phase lasts. If not set, the phase never ends. Only the last
phase can be indefinite. This field cannot be changed after a SubscriptionPhase
is
created.
recurring_price_money: Money
The amount to bill for each cadence
.
ordinal: Option<i64>
The position this phase appears in the sequence of phases defined for the plan, indexed from
0. This field cannot be changed after a SubscriptionPhase
is created.
Trait Implementations§
Source§impl Clone for SubscriptionPhase
impl Clone for SubscriptionPhase
Source§fn clone(&self) -> SubscriptionPhase
fn clone(&self) -> SubscriptionPhase
Returns a duplicate of the value. Read more
1.0.0 · Source§const fn clone_from(&mut self, source: &Self)
const fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source
. Read moreSource§impl Debug for SubscriptionPhase
impl Debug for SubscriptionPhase
Source§impl Default for SubscriptionPhase
impl Default for SubscriptionPhase
Source§fn default() -> SubscriptionPhase
fn default() -> SubscriptionPhase
Returns the “default value” for a type. Read more
Source§impl<'de> Deserialize<'de> for SubscriptionPhase
impl<'de> Deserialize<'de> for SubscriptionPhase
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 PartialEq for SubscriptionPhase
impl PartialEq for SubscriptionPhase
Source§impl Serialize for SubscriptionPhase
impl Serialize for SubscriptionPhase
impl Eq for SubscriptionPhase
impl StructuralPartialEq for SubscriptionPhase
Auto Trait Implementations§
impl Freeze for SubscriptionPhase
impl RefUnwindSafe for SubscriptionPhase
impl Send for SubscriptionPhase
impl Sync for SubscriptionPhase
impl Unpin for SubscriptionPhase
impl UnwindSafe for SubscriptionPhase
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> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
Source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
Compare self to
key
and return true
if they are equal.