pub struct StoreContext {
pub bundle_identifier: Option<String>,
pub bundle_name: Option<String>,
pub bundle_version: Option<String>,
pub receipt_url: Option<String>,
pub can_make_payments: bool,
pub device_verification_id: Option<String>,
pub is_bundled: bool,
pub executable_path: Option<String>,
}Expand description
Collects bundle context used alongside StoreKit APIs.
Fields§
§bundle_identifier: Option<String>Bundle identifier reported by StoreKit.
bundle_name: Option<String>Bundle display name reported by StoreKit.
bundle_version: Option<String>Bundle version reported by StoreKit.
receipt_url: Option<String>Receipt URL reported by StoreKit.
can_make_payments: boolWhether StoreKit reports that payments can be made.
device_verification_id: Option<String>Device verification identifier reported by StoreKit.
is_bundled: boolWhether StoreKit reported that the app is bundled.
executable_path: Option<String>Executable path reported by StoreKit.
Implementations§
Source§impl StoreContext
impl StoreContext
Sourcepub fn current() -> Result<Self, StoreKitError>
pub fn current() -> Result<Self, StoreKitError>
Fetches the current bundle context used alongside StoreKit APIs.
Sourcepub fn can_make_payments() -> Result<bool, StoreKitError>
pub fn can_make_payments() -> Result<bool, StoreKitError>
Returns whether StoreKit reports that payments can be made.
Sourcepub fn device_verification_id() -> Result<Option<String>, StoreKitError>
pub fn device_verification_id() -> Result<Option<String>, StoreKitError>
Fetches the StoreKit device verification identifier.
Sourcepub fn current_products<I, S>(
identifiers: I,
) -> Result<Vec<Product>, StoreKitError>
pub fn current_products<I, S>( identifiers: I, ) -> Result<Vec<Product>, StoreKitError>
Fetches current StoreKit products for the supplied identifiers.
Sourcepub fn current_entitlements() -> Result<TransactionStream, StoreKitError>
pub fn current_entitlements() -> Result<TransactionStream, StoreKitError>
Creates a stream of current StoreKit entitlements.
Sourcepub fn transaction_updates() -> Result<TransactionStream, StoreKitError>
pub fn transaction_updates() -> Result<TransactionStream, StoreKitError>
Creates a stream of StoreKit transaction updates.
Sourcepub fn current_storefront() -> Result<Option<Storefront>, StoreKitError>
pub fn current_storefront() -> Result<Option<Storefront>, StoreKitError>
Fetches the current StoreKit storefront.
Sourcepub fn app_transaction() -> Result<VerificationResult<AppTransaction>, StoreKitError>
pub fn app_transaction() -> Result<VerificationResult<AppTransaction>, StoreKitError>
Fetches the shared StoreKit app transaction.
Sourcepub fn receipt() -> Result<Option<AppReceipt>, StoreKitError>
pub fn receipt() -> Result<Option<AppReceipt>, StoreKitError>
Fetches the current app receipt used by StoreKit.
Trait Implementations§
Source§impl Clone for StoreContext
impl Clone for StoreContext
Source§fn clone(&self) -> StoreContext
fn clone(&self) -> StoreContext
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for StoreContext
impl Debug for StoreContext
Source§impl PartialEq for StoreContext
impl PartialEq for StoreContext
Source§fn eq(&self, other: &StoreContext) -> bool
fn eq(&self, other: &StoreContext) -> bool
self and other values to be equal, and is used by ==.