UnityEarlyTransactionObserver.h 657 B

123456789101112131415161718192021222324
  1. #pragma once
  2. #import <StoreKit/StoreKit.h>
  3. #import "LifeCycleListener.h"
  4. @protocol UnityEarlyTransactionObserverDelegate <NSObject>
  5. - (void)promotionalPurchaseAttempted:(SKPayment *)payment;
  6. @end
  7. @interface UnityEarlyTransactionObserver : NSObject<SKPaymentTransactionObserver, LifeCycleListener> {
  8. NSMutableSet *m_QueuedPayments;
  9. }
  10. @property BOOL readyToReceiveTransactionUpdates;
  11. // The delegate exists so that the observer can notify it of attempted promotional purchases.
  12. @property(nonatomic, weak) id<UnityEarlyTransactionObserverDelegate> delegate;
  13. + (UnityEarlyTransactionObserver*)defaultObserver;
  14. - (void)initiateQueuedPayments;
  15. @end